Django unenforce HTTPS connection on development server

筅森魡賤 提交于 2019-12-13 19:09:36

问题


I have a Django project that I've pushed to Bitbucket. I pulled the Django project from Bitbucket onto my production server. When I made my site live, I made various changes to the settings.py file. E.g. I set

SECURE_SSL_REDIRECT=True

I then pushed these changes to my repository on Bitbucket.

I then made changes to my Django project on my local, development server. I wanted to push these changes to my repository, but I was notified that first I would need to merge the repository with my local machine. I did this and then I had the settings.py file from my production environment on my development server. I changed the settings.py file so that it is suited for development purposes once again. E.g. I reset

SECURE_SSL_REDIRECT = False

Now when I run 'python manage.py runserver', I get a message saying "You're accessing the development server over HTTPS, but it only supports HTTP"

I've flushed out the database and I've reset the settings.py file to the way it was, but I still receive this error. Does anyone have any suggestions?

来源:https://stackoverflow.com/questions/36399206/django-unenforce-https-connection-on-development-server

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!