pm2-loggly
Installation
pm2 install pm2-loggly
Configuration
Default Configuration
You can see this inside of package.json
.
"config":
Explanation of Configuration Options
logglyClient.token
: a token fromhttps://your-subdomain.loggly.com/tokens
logglyClient.subdomain
: your Loggly subdomainlogglyClient.tags
: a comma-delimited list of global tags applied to all logspm2Apps
: a comma-delimited list of apps allowed to log to Loggly (logs will be tagged with the app name as well)
Recommended Way of Setting the Configuration Options
In your terminal run each of these commands:
pm2 set pm2-loggly.logglyClient.token my-extra-long-token-from-logglypm2 set pm2-loggly.logglyClient.subdomain mylogglysubdomainpm2 set pm2-loggly.logglyClient.tags tag1,tag2,tag3pm2 set pm2-loggly.pm2Apps app1,app2,app3
Optional Way of Setting the Configuration Options
- Edit
~/.pm2/module_conf.json
and add something like this inside the first{}
:
"pm2-loggly":
- Edit
pm2-loggly/package.json
and replace the default configuration above with:
"config":