Skip to content

Instantly share code, notes, and snippets.

@wcharczuk
Created February 17, 2012 22:38
Show Gist options
  • Save wcharczuk/1855878 to your computer and use it in GitHub Desktop.
Save wcharczuk/1855878 to your computer and use it in GitHub Desktop.
sample nginx config
worker_processes 1;
#pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
upstream myapp {
server www.bing.com weight=2;
server www.google.com weight=1;
}
server {
listen 8080;
server_name myapp.com;
location / {
proxy_pass http://myapp;
}
error_page 501 502 503 504 @maintenance;
location @maintance {
rewrite ^(.*)$ /down.html break;
root /var/www/;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment