Proper ssl/https handling
See original GitHub issueI am running django-cms from latest development branch:
-e git+https://github.com/divio/django-cms.git@946ac2b3cb1c95827bf879a4c2254331ee185eb3#egg=django_cms-origin/develop
I have big troubles when accessing it via https because many requests seem to be hardcoded to http. For example the “Save” button in the admin interface does not work. It saves the instance, but does not reload/refresh the page because this request is blocked by the browser (wants to load via http, but page was loaded via https). Another example is that cancelling the addition of a plugin (so deleting it) causes errors: it deletes the plugin, but the “popup” stays in the browser and nothing seems to change. When you hit cancel again you understandably get a 404 because the plugin is already gone. You can workaround all this by always manually hitting F5, but this is annoying (and not DAU friendly) 😃 I did not find the places where to fix it, so maybe somebody who’s used to the architecture of djangocms can fix it?
Issue Analytics
- State:
- Created 10 years ago
- Comments:21 (21 by maintainers)
Top GitHub Comments
Okay I found out how it works. The problem was not that the proxy is on another host, but it has to set a special header. E.g. for nginx you nee this:
Also you have to put this line in your django settings:
Finally found it in django doc here: https://docs.djangoproject.com/en/dev/topics/security/#ssl-https and here: https://docs.djangoproject.com/en/dev/ref/settings/#std:setting-SECURE_PROXY_SSL_HEADER
Thanks for your help and ideas. Maybe this will help somebody later 😃
thank you very much for the great addition 👍