mirror of
https://github.com/thib8956/nginx-proxy
synced 2025-07-02 06:45:45 +00:00
Removed HSTS when HTTPS_METHOD=noredirect, added tests, improved docs wrt HSTS
This commit is contained in:
@ -153,7 +153,9 @@ server {
|
||||
ssl_dhparam {{ printf "/etc/nginx/certs/%s.dhparam.pem" $cert }};
|
||||
{{ end }}
|
||||
|
||||
{{ if (ne $https_method "noredirect") }}
|
||||
add_header Strict-Transport-Security "max-age=31536000";
|
||||
{{ end }}
|
||||
|
||||
{{ if (exists (printf "/etc/nginx/vhost.d/%s" $host)) }}
|
||||
include {{ printf "/etc/nginx/vhost.d/%s" $host }};
|
||||
|
Reference in New Issue
Block a user