Skip to content

Instantly share code, notes, and snippets.

@jshawl
Created October 21, 2014 18:25
Show Gist options
  • Save jshawl/cc24a4c7100c09fabc5d to your computer and use it in GitHub Desktop.
Save jshawl/cc24a4c7100c09fabc5d to your computer and use it in GitHub Desktop.
upstream app {
# Path to Unicorn SOCK file, as defined previously
server unix:/tmp/unicorn.superheros.sock fail_timeout=0;
}
server{
listen 80;
server_name qed.im;
root /var/www/superheros;
try_files $uri/index.html $uri @app;
location @app {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_pass http://app;
}
error_page 500 502 503 504 /500.html;
client_max_body_size 4G;
keepalive_timeout 10;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment