diff --git a/script/scheduler.rb b/script/scheduler.rb index 076a91d82..5be7db8c3 100755 --- a/script/scheduler.rb +++ b/script/scheduler.rb @@ -47,6 +47,7 @@ daemon_options = { name = 'scheduler' Daemons.run_proc(name, daemon_options) do + if ARGV.include?('--') ARGV.slice! 0..ARGV.index('--') else @@ -55,6 +56,12 @@ Daemons.run_proc(name, daemon_options) do after_fork(dir) + Rails.logger.info 'Scheduler started.' + + at_exit do + Rails.logger.info 'Scheduler stopped.' + end + require 'scheduler' Scheduler.threads end