Django redirects in reverse proxy setups
Starting with django-1.3.1 you'll get redirect failures for reverse proxy setups (cherokee and cherrypy in my case). The reason is that relative paths that you feed to HttpResponseRedirect are converted into absolute URLs using META['HTTP_HOST'] which is actually the IP of the reverse proxy. To fix this add the following line to settings.py:
- USE_X_FORWARDED_HOST = True
Category: Django



Discussion
Very easy to fix. Thanks :D
Leave a Comment :
Leave a Comment