-
Notifications
You must be signed in to change notification settings - Fork 3k
Enable :force_ssl
in :prod
environment by default
#6435
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
If i remember correct, the reason why this is disabled is because, if you run prod on your machine (which you may do the first time for testing) and then you access localhost+HSTS, it borks your localhost unless you go to specific settings in each browser and revert that. So your development environments breaks in very non obvious ways. |
When accessing the app through |
Good! And IIRC, the other concern is related to proxy headers. You are currently setting Another option is to not set |
Indeed ! I removed |
I think it might be. I for one use it on a number of projects. |
To be clear, it means that accessing |
Another option could be to add it as a comment, explain that it's a good practice to activate it, and link to the Force SSL section of the documentation so that people can configure it as they need it. |
This is a proposal to enable the
:force_ssl
option and HSTS by default on new installations.HSTS is a standard nowadays, recommend for most, if not all, websites or webapps. However,
for I feel like it can be easy to miss if you are not really into web security - just like
CSP, so thanks for making it a default now ❤️
The given option may not be the best suited for a default installation. I basically
copy-pasted the "Using SSL" part of the documentation, making it as generic as possible.