Starting background tasks with Capistrano
For my RubyOnRails-App I have to start a background job at the end of Capistrano deployment. For this, I tried the following in deploy.rb: run "nohup #{current_path}/script/runner -e production 'Scheduler.start' &", :pty => true Sometimes this works, but most of the time it does not start the process (= not listed in ps -aux). And there are no error messages. And there is no nohup.out, not in the home directory and not in the rails app directory. I tried using trap('SIGHUP', 'IGNORE') in scheduler.rb instead of nohup, but the result is the same. The only way to get it work is removing the "