-
Notifications
You must be signed in to change notification settings - Fork 0
Deployment
Xu Tao edited this page Nov 14, 2013
·
1 revision
upstream myapp {
server 127.0.0.1:2000;
}
server {
listen 80;
server_name beta.wanmen.org;
root /root/cats2000;
index index.html;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
try_files /system/maintenance.html $uri $uri/index.html $uri.html @ruby;
}
location @ruby {
proxy_pass http://myapp;
}
}
RAILS_ENV="production" rake assets:precompile
rails server -e production -p 2000 -d