node-supervisor
node-supervisor copied to clipboard
Send SIGTERM instead of a crash
Howdy
Do you think you could add a new option to send a SIGTERM to the node.js app instead of crashing it?
Like that I would be able to build in a mechanism respecting current connections, shutting them down gracefully with a 502 header message like "Server is in the process of restarting".
What do you think?
Cheers Michael
supervisor is calling process.kill, which sends a SIGTERM by default...
You're right. Just played around and I can gracefully close the app with your supervisor.
Ticket closed.
This PR will fix this :)
https://github.com/isaacs/node-supervisor/pull/132