pm2-hive / pm2-syslog

PM2 module to redirect application logs to syslog
41 stars 28 forks source link

Update app.js to include pm2 syslog tag #4

Closed kylegato closed 8 years ago

kylegato commented 8 years ago

Tag the syslog output as pm2 so that in the logs it does not show just "hostname - error" but "hostname - pm2 - error"

BEFORE: May 25 16:29:08 noc.pv.domain.com /root/.pm2/node_modules/ain2/index.js[81027]:Process test2 restarted 21

AFTER: May 25 16:44:35 noc.pv.domain.com pm2[86262]:Process test2 restarted 114