fix no sidetiq when using demon

This commit is contained in:
Sam 2013-10-24 15:58:28 +11:00
parent 636976e5d4
commit 89f801ac04

View file

@ -151,8 +151,10 @@ class Demon::Sidekiq < Demon::Base
def after_fork def after_fork
require 'sidekiq/cli' require 'sidekiq/cli'
begin begin
# Reload initializer cause it needs to run after sidekiq/cli
# was required
load Rails.root + "config/initializers/sidekiq.rb"
cli = Sidekiq::CLI.instance cli = Sidekiq::CLI.instance
cli.parse([]) cli.parse([])
cli.run cli.run