Daemon


(Berger, Daniel) #1

By daemon, do you simply mean that you want to run it in the background? If
so, setsid() is the method you want (it’s a Kernel method).

Regards,

Dan

···

-----Original Message-----
From: Vivek Nallur [mailto:nvivek@konark.ncst.ernet.in]
Sent: Friday, June 14, 2002 9:18 AM
To: ruby-talk@ruby-lang.org
Subject: daemon

How do I make a script run as a deamon in ruby? I’m trying to create a
variation on fetchmail and hence I want it to run in daemon mode, when
invoked by root or so ‘optioned’