Vegas should trap 'HUP' and restart.
Opened this issue · 1 comments
bobthecow commented
When a daemonized vegas app is killed with -HUP
, it should restart with the same arguments and configuration options and working directory as before.
This would allow vegas apps to run:
Process.kill :HUP, Process.pid
... to reload themselves. It would also allow adding a --restart
option to vegas:
def restart!
pid = File.read(pid_file)
logger.warn "Sending HUP to #{pid.to_i}"
Process.kill(:HUP, pid.to_i)
end
danielb2 commented
👍
Just to expand, this is useful if an app using Vegas has been upgraded to a new version in order to be able to restart it on the fly without an explicit shutdown etc.