I have some useful logging in my node app that I write to console.log
node server.js >> /var/log/nodeserver.log 2>&1
However, when trying the same under pm2:
pm2 start server.js >> /var/log/pm2server.log 2>&1
the log file only shows the pm2 startup information
Is application logging at all possible with pm2? On their page they discuss logging, and show an image with text like "log message from echo.js"
, but I see nothing about getting custom information into the pm2 log.