News for hackers. Stuff that matters.
Re:PM2: Production Process Manager with a Built-In Load Bala... by Kharacternyk on Sunday April 07, 2024 @12:33PM (#39961838)
I know about templates, but I don't believe they are designed for fungible copies. You can run a bunch of [email protected], but it's not the same UX as `pm2 start my-app -i number-of-copies`.
Re:PM2: Production Process Manager with a Built-In Load Bala... by stephenr on Sunday April 07, 2024 @09:21PM (#39965400)
They work very well for "worker" processes. The default ssh package on Debian uses systemd template units for the user process; I've used them extensively for job queue workers, in combination with max execution time and a separate timed job to monitor queue load (essentially automatic scale up/down of queue workers).

Realistically if your prod environment relies on you manually running `pm2... ` or whatever, you're doing something wrong. User Experience should have about 0% impact on how your service daemons run.