I'm trying to deploy a node.js app with logs being written to /var/log/nodejs/myapp.
I've tried Forever and PM2, but even though the log directory has the correct permissions and I'm passing the correct options (I think), the files are not created.
With Forever, I'm starting the app this way:
forever start ./app.js -l /var/log/nodejs/myapp/forever.log -o /var/log/nodejs/myapp/out.log -e /var/log/nodejs/myapp/err.log
After starting, if I run forever logs, I see that it is saving to the default .forever/ directory.
With PM2 I used the respective log options as well, but nothing is being written. The pm2 logs command show me all the log info, but no file is created.
Any ideas?