I am using Daemons 1.1.9. I am not able to get the daemons logging to a log file. My daemons control file is as follows:
require 'rubygems'
require 'daemons'
@options = {
:dir_mode => :script,
:dir => 'pids',
:multiple => false,
:backtrace => true,
:monitor => false,
:log_dir => 'log',
:log_output => true
}
Daemons.run('myserver.rb', @options)
The pids and log directories are both just one down from the root folder and the pid files are being written successfully so I know it's not a misspecification of the directory/directory mode. The files, myserver.rb.log and myserver.rb.output, exist in the log directory. What am I doing wrong? Thanks in advance.
The following worked for me, I am not much of a ruby guy so this may be a terrible hack.