-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature: allow to set deep monitoring via environment (PM2_DEEP_MONIT…
…ORING=true on start/restart)
- Loading branch information
Showing
3 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
|
||
#!/usr/bin/env bash | ||
|
||
SRC=$(cd $(dirname "$0"); pwd) | ||
source "${SRC}/include.sh" | ||
|
||
cd $file_path | ||
|
||
# With start | ||
$pm2 start echo.js | ||
should 'should deep_monitoring' 'deep_monitoring' 0 | ||
|
||
$pm2 delete all | ||
|
||
PM2_DEEP_MONITORING=true $pm2 start echo.js | ||
should 'should deep_monitoring' 'deep_monitoring' 1 | ||
|
||
$pm2 delete all | ||
|
||
# With restart | ||
$pm2 start echo.js | ||
should 'should deep_monitoring' 'deep_monitoring' 0 | ||
PM2_DEEP_MONITORING=true $pm2 restart echo | ||
should 'should deep_monitoring' 'deep_monitoring' 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters