Skip to content

Instantly share code, notes, and snippets.

@jmervine
Created March 19, 2012 20:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jmervine/2127051 to your computer and use it in GitHub Desktop.
Save jmervine/2127051 to your computer and use it in GitHub Desktop.
nginx default proxy example for rails
server {
#root /usr/share/nginx/www;
root /home/myuser/blog/public;
index index.html index.htm;
server_name app.hostname;
location ~ ^/assets/ {
root /home/myuser/blog/app/assets/$1;
}
location / {
proxy_pass http://127.0.0.1:3000;
}
#location /doc {
# root /usr/share;
# autoindex on;
# allow 127.0.0.1;
# deny all;
#}
#location /images {
# root /usr/share;
# autoindex off;
#}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment