How to properly implement a daemon on node?

Hi! With Noda never did anything so silly question.
There is a function that should run every minute and execute certain actions. Just like all

setInterval(bot.check, 60000);

If you run the app in my node bot.jsthen everything works as expected.
If pm2 start bot.js - does not work.

What am I doing wrong? Thank you.
July 2nd 19 at 14:23
0 answer

Find more questions by tags JavaScriptNode.js