Skip to content

Instantly share code, notes, and snippets.

@koi-chan
Last active January 24, 2016 12:29
Show Gist options
  • Save koi-chan/4d6d31c325ee39692a8e to your computer and use it in GitHub Desktop.
Save koi-chan/4d6d31c325ee39692a8e to your computer and use it in GitHub Desktop.
# vim: filetype=nginx
server {
listen 80;
server_name dodontof.example.com;
root /home/nginx/dodontof.example.com/public_html;
index index.html index.htm;
client_max_body_size 128M;
access_log /home/nginx/dodontof.example.com/logs/access.log combined;
error_log /home/nginx/dodontof.example.com/logs/error.log;
location ~ ^/.*\.rb$ {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header Host $http_host;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.html;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment