ecosystem.json
PM2 ecosystem config file
| Type | object |
|---|---|
| File match |
ecosystem.json
ecosystem.yml
ecosystem.yaml
ecosystem.config.json
ecosystem.config.yml
ecosystem.config.yaml
|
| Schema URL | https://catalog.lintel.tools/schemas/schemastore/ecosystem-json/latest.json |
| Source | https://www.schemastore.org/pm2-ecosystem.json |
Validate with Lintel
npx @lintel/lintel check
Properties
The apps property is an array of object where each object contains the configuration for each process.
The deploy property is an object where each of its properties is an object which defines a deployment environment.
3 nested properties
11 nested properties
SSH key path. Defaults to $HOME/.ssh
SSH user
SSH host
SSH options with no command-line flag, see 'man ssh'
GIT remote/branch
GIT remote
path in the server
Pre-setup command or path to a script on your local machine
Post-setup commands or path to a script on the host machine
pre-deploy action
post-deploy action
11 nested properties
SSH key path. Defaults to $HOME/.ssh
SSH user
SSH host
SSH options with no command-line flag, see 'man ssh'
GIT remote/branch
GIT remote
path in the server
Pre-setup command or path to a script on your local machine
Post-setup commands or path to a script on the host machine
pre-deploy action
post-deploy action
11 nested properties
SSH key path. Defaults to $HOME/.ssh
SSH user
SSH host
SSH options with no command-line flag, see 'man ssh'
GIT remote/branch
GIT remote
path in the server
Pre-setup command or path to a script on your local machine
Post-setup commands or path to a script on the host machine
pre-deploy action
post-deploy action
Definitions
Path of the script to launch
Process name in the process list. Defaults to script filename without the extension (app for app.js)
Current working directory to start the process with. Defaults to CWD of the current environment (from your shell)
Arguments to pass to the script
Interpreter absolute path. Defaults to node
Options to pass to the interpreter
File path for stderr (each line is appended to this file)
File path for stdout (each line is appended to this file)
If set to true, avoid to suffix logs file with the process id
Alias to combine_logs
File path where the pid of the started process is written by pm2. Defaults to ~/.pm2/pids/app_name-id.pid
Disable all logs storage
Define a specific log output type
Format for log timestamps in moment.js format (eg YYYY-MM-DD HH:mm Z)
Specify environment variables to be injected
Specify environment variables to be injected (when passing --env)
Restart the app if an amount of memory is exceeded (format: /0-9?/ K for KB, 'M' for MB, 'G' for GB, default to B)
Time in ms to wait before restarting a crashing app
Enable or disable the source map support
Enable or disable the source map support
Make the process wait for a process.send('ready')
Number of instances to be started in cluster mode
Time in ms before sending the final SIGKILL signal after SIGINT
Time in ms before forcing a reload if app is still not listening/has still not sent ready
A cron pattern to restart your app
Enable or disable the versioning metadatas (vizion library)
Enable or disable auto restart after process failure
Enable or disable the watch mode
List of paths to ignore (regex)
Object that will be used as an options with chokidar (refer to chokidar documentation)
Minimum uptime of the app to be considered started (format is /[0-9]+(h|m|s)?/, for hours, minutes, seconds, default to ms)
Number of times a script is restarted when it exits in less than min_uptime
Set the execution mode
Start a script even if it is already running (only the script path is considered)
Append the environment name to the app name
List of commands executed after a pull/upgrade operation performed from Keymetrics dashboard
Shutdown an application with process.send('shutdown') instead of process.kill(pid, SIGINT)
Enable or disable the transaction tracing
Enable or disable the transaction tracing
Specify the name of an environment variable to inject which increments for each cluster
Rename the NODE_APP_INSTANCE environment variable. Defaults to NODE_APP_INSTANCE
Excludes global variables starting with "REACT_" and will not allow their penetration into the cluster
Enable or disable apm wrapping
Enable or disable apm wrapping
Only kill the main process, not detached children
Shortcut to inject a PORT environment variable
Set user id. Defaults to current user uid
Set group id. Defaults to current user gid
SSH key path. Defaults to $HOME/.ssh
SSH user
SSH host
SSH options with no command-line flag, see 'man ssh'
GIT remote/branch
GIT remote
path in the server
Pre-setup command or path to a script on your local machine
Post-setup commands or path to a script on the host machine
pre-deploy action
post-deploy action