-V,--version | Outputs the version number |
-v | Gets version |
-s,--silent | Hides all messages |
-m,--mini-list | Displays a compacted list without formatting |
-f,--force | Forces actions |
--disable-logs | Do not write logs |
-n,--name <command> | Sets a name for script |
-i,--instances <command> | Launches [number] instances (for networked app)(load balanced) |
--parallel <command> | Number of parallel actions (for restart/reload) |
-l,--log [command] | Specifies entire log file (error and out are both included) |
-o,--output <command> | Specifies out log file |
-e,--error <command> | Specifies error log file |
-p,--pid <command> | Specify pid file |
-k,--kill-timeout <command> | Delays before sending final SIGKILL signal to process |
--listen-timeout <command> | Listen timeout on application reload |
--max-memory-restart <command> | Specify max memory amount used to autorestart (in octet or use syntax like 100M) |
--restart-delay <command> | Specify a delay between restarts (in milliseconds) |
--env <command> | Specify environment to get specific env variables |
--log-type <command> | Specify log output style (raw by default, json optional) |
-x,--execute-command | Execute a program using fork system |
--max-restarts [command] | Only Restart the script COUNT times |
-u,--user <command> | Defines user when generating startup script |
--uid <command> | Runs target script with <uid> rights |
--gid <command> | Runs target script with <gid> rights |
--cwd <command> | Runs target script as <username> |
--hp <command> | Defines home path when generating startup script |
--wait-ip | Overrides systemd script to wait for full internet connectivity to launch pm2 |
--service-name <command> | Defines service name when generating startup script |
-c,--cron <command> | Restarts a running process based on a cron pattern |
-w,--write | Writes configuration in local folder |
--interpreter <command> | The interpreter pm2 should use for executing app (bash, python…) |
--interpreter-args <command> | Interprets options (alias of –node-args) |
--log-date-format <command> | Adds custom prefix timestamp to logs |
--no-daemon | Runs pm2 daemon in the foreground if it doesn’t exist already |
-a,--update-env | Updates environment on restart/reload (-a <=> apply) |
–-source-map-support | Force source map support |
–-only <command> | With json declaration, allow to only act on one application |
–-disable-source-map-support | Force source map support |
–-wait-ready | Asks pm2 to wait for ready event from your app |
–-merge-logs | Merges logs from different instances but keep error and out separated |
–-watch <command...> | Watches application folder for changes (default: ) |
–-ignore-watch <command...> | Folder/files to be ignored watching |
–-node-args <command> | Space delimited arguments to pass to node in cluster mode |
–-no-color | Skip colors |
–-no-vizion | Starts an app without vizion feature (versioning control) |
–-no-autorestart | Starts an app without automatic restart |
–-no-treekill | Only kills the main process, not detached children |
–-no-pmx | Starts an app without apm |
–-no-automation | Starts an app without apm |
–-trace | Enables transaction tracing with km |
–-disable-trace | Disables transaction tracing with km |
–-attach | Attaches logging after your start/restart/stop/reload |
–-sort <command> | Sort process according to field’s name |
–-v8 | Enables v8 data collecting |
–-event-loop-inspector | Enables event-loop-inspector dump in apm |
–-deep-monitoring | Enables all monitoring tools (equivalent to –v8 –event-loop-inspector –trace) |
-h,–-help | Outputs usage information |