Skip to content

Instantly share code, notes, and snippets.

@csabatini
Created May 8, 2017 15:27
Show Gist options
  • Save csabatini/163f3d74e9a8e787c7273a038e66d2e8 to your computer and use it in GitHub Desktop.
Save csabatini/163f3d74e9a8e787c7273a038e66d2e8 to your computer and use it in GitHub Desktop.
nginx - redirect HTTP to HTTPS
server {
listen 80;
server_name mydomain.com;
return 301 https://$server_name$request_uri;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment