Created
December 20, 2014 00:05
-
-
Save Dirrk/77b71286ac0987c09f04 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
# For gmtimonitor app in prod | |
user nobody; | |
worker_processes 1; | |
daemon off; | |
error_log /app/nginx/logs/error.log; | |
events { | |
worker_connections 1024; | |
} | |
http { | |
include mime.types; | |
default_type application/octet-stream; | |
log_format main '$remote_addr - $remote_user [$time_local] "$request" ' | |
'$status $body_bytes_sent "$http_referer" ' | |
'"$http_user_agent" "$http_x_forwarded_for" $request_time'; | |
access_log logs/access.log main; | |
sendfile on; | |
tcp_nopush on; | |
keepalive_timeout 65; | |
# nodeapps | |
upstream gdpstats { | |
server 127.0.0.1:4000; | |
} | |
# gdpstats | |
server { | |
listen 80; | |
server_name moc-lx00010101.gmti.gbahn.net localhost moc-gdpstats.gmti.gbahn.net phx-gdpstats.gmti.gbahn.net; | |
access_log logs/access.gdpstats.gmti.gbahn.net.log main; | |
location / { | |
proxy_redirect off; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_set_header X-Forwarded-Proto $scheme; | |
proxy_set_header Host $http_host; | |
proxy_set_header X-NginX-Proxy true; | |
proxy_set_header Connection "upgrade"; | |
proxy_set_header Upgrade $http_upgrade; | |
proxy_http_version 1.1; | |
proxy_pass http://gdpstats; | |
} | |
error_page 500 502 503 504 /50x.html; | |
location = /50x.html { | |
root html; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment