[LRUG] Ruby Daemons?

James Fairbairn james at netlagoon.com
Tue Dec 1 15:35:33 PST 2009


Hello, bit late to this thread, but hey.

> What does everyone else use to run background daemons in ruby?

Have you looked at djb's daemontools[1]? It's not Ruby, but a bunch of
Unixy C programs that help you do stuff like

 * Supervise your process, making sure that it's up when it's supposed
to be up, and down when it's supposed to be down;
 * Redirect stdout/stderr to a rolling log file, adding an optional
timestamp to each line along the way

I think it's better not to do any process-management stuff (i.e.
forking, going into the background) in one's own program unless it's
really necessary.

Hope this helps. What does everyone else think?

J

[1] http://cr.yp.to/daemontools/faq/create.html#fghack



More information about the Chat mailing list