# Restart just the thin server described by that config
sudo thin -C /etc/thin/mysite.yml restart
Nginx will continue running and proxying requests. If you have your Nginx set to use multiple upstream servers, e.g.
server {
listen 80;
server_name myapp.mysite.com;
# ...
location / {
try_files $uri $uri/index.html /cache$uri.html $uri.html @proxy;
}
location @proxy {
proxy_pass http://myapp.rails;
}
}
upstream myapp.rails {
server 127.0.0.1:9001 max_fails=1 fail_timeout=10s;
server 127.0.0.1:9002 max_fails=1 fail_timeout=10s;
server 127.0.0.1:9003 max_fails=1 fail_timeout=10s;
}
…then each instance will be restarted in turn and Nginx will automatically route requests around one of the proxies if it's down.