Created
October 19, 2012 04:24
-
-
Save davidbanham/3916231 to your computer and use it in GitHub Desktop.
Example nginx 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 localhost:81; | |
location /RPC2 { | |
auth_basic "Restricted"; | |
auth_basic_user_file htpasswd; | |
include scgi_params; | |
scgi_pass localhost:5000; | |
} | |
} | |
server { | |
listen 80; | |
location /incoming/ { | |
proxy_pass http://localhost:3000/incoming/; | |
include /etc/nginx/proxy.conf; | |
} | |
location / { | |
return 301 https://$host$request_uri; | |
} | |
} | |
server { | |
listen 443; | |
ssl on; | |
ssl_certificate /etc/nginx/server.crt; | |
ssl_certificate_key /etc/nginx/server.key; | |
location / { | |
proxy_pass http://localhost:3000/; | |
include /etc/nginx/proxy.conf; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment