Files
ironic/releasenotes/notes/handle-http-multiple-redirection-cfa2b4693e1db82f.yaml
Ettore Simone 2585cb4e9d Allow multiple HTTP redirects for image source
Added multiple redirection response for HttpImageService.validate_href()
function inside ironic/common/image_service.py:
- 301: MOVED_PERMANENTLY
- 302: FOUND
- 307: TEMPORARY_REDIRECT
- 308: PERMANENT_REDIRECT

For all the response, the HTTP server should generate a Location header field
containing a URI as new reference.

Closes-Bug: #2126069
Change-Id: I985b3587984ba78570c3a163c08af58cf8a5d0c1
Signed-off-by: Ettore Simone <ettore.simone@gmail.com>
2025-10-02 11:17:40 +02:00

12 lines
634 B
YAML

---
fixes:
- |
Fixed HttpImageService.validate_href() ImageRefValidationFailed exception
if protocol is HTTP/HTTPS and the HTTP header response is a redirection
other then 301 (MOVED_PERMANENTLY). HTTP/HTTPS protocol is often used
under standalone Ironic configuration to identify an image source (e.g
--instance-info image_source=<URI>). The HTTP server may use redirection
to load balance or geographically distribute the requests, or simply point
to the correct URL. The redirection may vary from 301 (MOVED_PERMANENTLY),
to 302 (FOUND), or 307 (TEMPORARY_REDIRECT), and 308 (PERMANENT_REDIRECT).