mirror of
https://github.com/mastodon/mastodon.git
synced 2024-08-20 21:08:15 -07:00
Optionally load the hsts with preload
This commit is contained in:
parent
736b4283b0
commit
dcc67e86a6
1 changed files with 1 additions and 0 deletions
|
@ -46,6 +46,7 @@ Rails.application.configure do
|
||||||
|
|
||||||
config.force_ssl = true
|
config.force_ssl = true
|
||||||
config.ssl_options = {
|
config.ssl_options = {
|
||||||
|
hsts: { preload: ENV['HSTS_PRELOAD'] == 'true' },
|
||||||
redirect: {
|
redirect: {
|
||||||
exclude: -> request { request.path.start_with?('/health') || request.headers["Host"].end_with?('.onion') || request.headers["Host"].end_with?('.i2p') }
|
exclude: -> request { request.path.start_with?('/health') || request.headers["Host"].end_with?('.onion') || request.headers["Host"].end_with?('.i2p') }
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue