4 ms·
How do you feel about using pm2 inside of a container? At work, most of our app is docker-composed in one VPS (early B2B product with few customers). I would l
by chamomeal 3y ago
How do you feel about using pm2 inside of a container?
At work, most of our app is docker-composed in one VPS (early B2B product with few customers). I would like to have the multiple-process benefits of PM2, but I don’t want to spin up a whole load balancer for it, or split the node service from the other services. Everything is so simple right now and I’d like to keep it that way lol.
Last time I googled this I found conflicting opinions, but if I can just stuff PM2 into my node container, I’d be a happy dev!
- ilaksh 3y agoNode.js cluster https://nodejs.org/api/cluster.html https://nodejs.org/api/cluster.html or worker_threads
- dalore 3y agoWe use PM2 in a docker container since we got a memory leak and PM2 has a memory limiter option that allows us to kill and restart a process when it uses too much memory. If we let it grow the response time starts to drop due to GC taking longer and longer.