Replies: 1 comment 3 replies
-
Never heard of |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Problem:
X-Accel-Redirect
doesn't work correctly with Traefik as reverse proxyContext
I'm using
cookiecutter-django
along withdjango-protected-media
to serve private media files viaX-Accel-Redirect
. This mechanism works well when using nginx directly as the reverse proxy.However, when using Traefik as the main ingress (as recommended in cookiecutter-django),
X-Accel-Redirect
becomes ineffective and results in empty responses.Behavior Diagram
Root Cause
Traefik does not support
X-Accel-Redirect
internally — this is an nginx-only feature.Traefik acts only as a forwarding proxy; it doesn’t interpret or process the
X-Accel-Redirect
header. Therefore, any attempt to use it directly withdjango-protected-media
and Traefik alone results in:200 OK
responseX-Accel-Redirect
headerBeta Was this translation helpful? Give feedback.
All reactions