Last active
August 29, 2015 14:12
-
-
Save Nolski/c96c870b426dce2bd7c8 to your computer and use it in GitHub Desktop.
nolski.rocks.conf
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 { | |
listen 80; | |
server_name nolski.rocks; | |
# Removing server headers | |
proxy_pass_header Server; | |
server_tokens off; | |
return 301 https://nolski.rocks$request_uri; | |
} | |
server { | |
listen 443 ssl; | |
server_name nolski.rocks; | |
# Removing server headers | |
proxy_pass_header Server; | |
server_tokens off; | |
ssl_certificate /etc/nginx/certs/nolski_rocks.crt; | |
ssl_certificate_key /etc/nginx/certs/nolski_rocks.key; | |
location / { | |
proxy_pass http://localhost:8000; | |
proxy_set_header Host $host; | |
proxy_hide_header X-powered-by; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment