Open lumos42 opened 1 year ago
See #5208
This is a different issue where I don't get an error, but at the same time it fails to stop the restarting even after exit status 0
same issue on 5.3.0
same issue on 5.3.0
install the dev version resolve this problem npm install -g github:Unitech/pm2#development
same issue on 5.3.0
It does not work with stop_exit_codes: [0],
and works with any other custom exit code, i.e. stop_exit_codes: [42],
.
Tests for this feature in the repo check for stop_exit_codes: [12, 42],
so they don't reach problem with exit code 0 (I guess).
UPD: For strange unknown reason, setting stopExitCodes: [93],
, changing app, then setting stopExitCodes: [0],
and changing app again made it work. Maybe configs are cached?..
What's going wrong?
I have the following config for an application
Indexer only takes 10 seconds to run. I want it to run once every 5 minutes, but it should start again in case the system reboots and
resurrect
is called. The config looks right as per the docs, but stop_exit_codes = [0] doesn't seem to work. In the pm2 logs I can see that indexer indeed exits with code 0, but still it keeps running indexer every 3-4 seconds. This is the output ofpm2 logs
:How could we reproduce this issue?
pm2 save
pm2 kill
pm2 resurrect
Supporting information