Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env ruby
- require 'rubygems'
- require 'daemons'
- RAILS_ROOT = File.expand_path(File.join(File.dirname($0), '..'))
- options = {
- :dir_mode => :normal,
- :dir => File.join(RAILS_ROOT, %w(tmp pids)),
- :backtrace => true
- }
- Daemons.run_proc("job_runner", options) do
- require File.join(RAILS_ROOT, 'config', 'environment')
- Delayed::Worker.new.start
- end
Add Comment
Please, Sign In to add comment