remy / nodemon

Monitor for any changes in your node.js application and automatically restart the server - perfect for development
http://nodemon.io/
MIT License
26.13k stars 1.72k forks source link

Question not a bug - How to restart app on crash #2202

Closed moomoo-dev closed 2 months ago

moomoo-dev commented 2 months ago

I'm trying to have nodemon restart my app when it crashes... is this a possibility .. and if so how do I do it?

remy commented 2 months ago

Nodemon, intentionally, doesn't support this. It's used for development rather than to keep crashing apps from restarting. Something like pm2 might be a good match to your needs.

moomoo-dev commented 2 months ago

Thank you. I got Pm2 working, but I was hoping that this would work as well. I'll just use Pm2 :( LOL