开发者

How can I write a shell script that goes into a screen and invokes something?

开发者 https://www.devze.com 2023-02-05 16:46 出处:网络
My IRC bot sporadically dies sometimes and I have it in a screen. The way to invoke it again is node protobot.js.

My IRC bot sporadically dies sometimes and I have it in a screen. The way to invoke it again is node protobot.js.

I have to always find that screen and reinvoke it. I'd like a faster way.

How can I invoke screen reliably from within a shell script in order to invoke node to revive i开发者_运维百科t?


Your process needs care and feeding? Do not put it in the screen to begin with.

Investigate process monitoring, for instance with Monit, or God, or some other keep-it-alive software. There are tons of alternatives. When you've seen these two, the Net should provide you with pros and cons and other names of software.

0

精彩评论

暂无评论...
验证码 换一张
取 消