pm2 restart query

So i had to update a few lines of code in a file after i had deployed onto a droplet and started pm2. So I pushed the local change to git and pulled it in the server. Then on running the app, I realized the change wasn’t reflecting. After testing around what the issue was I tried stopping and starting again PM2. This worked as my changes got reflected. So does that mean anytime I update my codebase and pull the updates on server, I need to restart PM2. Wouldn’t it be a problem if say the app is a live around the clock app?

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi @sinhamahendra49,

Yes, it would seem that way.

Having said that, if you want to restart your App and see what and how the changes have been affected, I’ll recommend using staging App, test the changes there and wait until it’s out of business hours to restart your live APP.