Last active
February 12, 2019 18:27
-
-
Save envygeeks/92fd607bf0a4bd8c7faf5d28c273ddb2 to your computer and use it in GitHub Desktop.
[HSTS Nginx -> HTTPS] #nginx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
server_name _; | |
rewrite ^(.*) https://$host$1 permanent; | |
listen 80; | |
} | |
server { | |
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment