diff --git a/CHANGES/5879.bugfix b/CHANGES/5879.bugfix new file mode 100644 index 0000000000..9f9a71f6ae --- /dev/null +++ b/CHANGES/5879.bugfix @@ -0,0 +1 @@ +Started propagating headers from the content-app when using a non-default filesystem storage. diff --git a/pulpcore/content/handler.py b/pulpcore/content/handler.py index bc0c0181b8..5a2f157417 100644 --- a/pulpcore/content/handler.py +++ b/pulpcore/content/handler.py @@ -1026,12 +1026,12 @@ def _build_url(**kwargs): elif not domain.redirect_to_object_storage: return ArtifactResponse(content_artifact.artifact, headers=headers) elif domain.storage_class == "storages.backends.s3boto3.S3Boto3Storage": - raise HTTPFound(_build_url(http_method=request.method)) + raise HTTPFound(_build_url(http_method=request.method), headers=headers) elif domain.storage_class in ( "storages.backends.azure_storage.AzureStorage", "storages.backends.gcloud.GoogleCloudStorage", ): - raise HTTPFound(_build_url()) + raise HTTPFound(_build_url(), headers=headers) else: raise NotImplementedError()