This question is already is answered in other thread Node.js as a background service. You can use Forever, This is pretty good to re spawn server on event of unexpected behavior.
Want to Run Bot on Server 24/7
-
29-09-2022 - |
質問
I made a bot (https://github.com/JBader89/PlugBot) for a social music site, and I'd like to have it running 24/7. I used node.js to create and run it, so I was wondering if there's a way to use node.js to make it run continually?
解決
他のヒント
You can also use repl.it and uptime robot. its 100% free, and its easier to transfer code. it also has dark mode now!
所属していません StackOverflow