Continuously run process with pm2
I'm trying to have node processes run continuously. I am able to start them with pm2 through ssh from my local machine, but that automatically disconnects every morning at 00:00. How can I get pm2 to run these processes without ever shutting them down?
-
Hi Lauren, Thanks for the response! (And HB as well). I'd honestly never heard of Passenger before, so I'll look into that! A colleague has also been recommending I use Docker instead, what would be your thoughts on that? Thanks! 0 -
cPanel's support for docker right now (though extremely popular) is limited and it might be more work to get it running/support for it with docker. 0 -
Alright, good to know! Looking into Passenger, I believe my initial problem may have been poorly explained. I believe that whether I use pm2, Passenger, or even Docker, the server seems to reset every night and kill every lingering process (therefore killing my website). Is there a way for me to stop the server from killing them or, if it does, make them automatically restart? 0 -
Alright, good to know! Looking into Passenger, I believe my initial problem may have been poorly explained. I believe that whether I use pm2, Passenger, or even Docker, the server seems to reset every night and kill every lingering process (therefore killing my website). Is there a way for me to stop the server from killing them or, if it does, make them automatically restart?
I believe the reason for the restart script I noted is because there isn't a way to keep it from killing the process.0 -
Awesome, thanks @PluggedP93 for the info. 0
Please sign in to leave a comment.
Comments
7 comments