Closed viperey closed 6 years ago
For your application it would probalby be easiest if you called your script just using e.g. system()
and then within the script require 'daemons.rb'
and then call Daemons.daemonize()
. This way, the child script is detached from the parent process.
Oh, cool then it seems it was using the wrong design approach. Thanks for the advice!
Hi.
For some reason I'm not fully understanding the usage of the library for some cases. My use case is the following:
:script
argument).What's the better approach to achieve this behavior?
Example code:
I.e. This example code would throw an exception and child processes won't get
PPID=1
Thanks in advance and congratulations for the library :)