Search code examples
sidekiqcapistrano3

capistrano-sidekiq not "Starting processing"


I am not sure what I'm missing but somehow I don't get the line:

INFO: Starting processing, hit Ctrl-C to stop

which does show up if I start sidekiq manually from the prompt line.

I am having this error because I am using capistrano-sidekiq to manage sidekiq withing capistrano, in the log file all I got is:

Booting Sidekiq 4.1.1 with redis options INFO: Booting Sidekiq 4.1.1 with redis options {:url=>"redis://localhost:6379/1", :namespace=>"MyApp_staging"} INFO: Running in ruby 2.2.3p173 (2015-08-18 revision 51636) [x86_64-linux] INFO: See LICENSE and the LGPL-3.0 for licensing details. INFO: Upgrade to Sidekiq Pro for more features and support: http://sidekiq.org

Because the last line is missing

...Starting processing...

no jobs are processed.

When I run: bundle exec sidekiq -e staging every job is processed just like it should.

Any idea what could be the reason? I've shared the important files code, if it may help.


Solution

  • Capistrano daemonizes. Sidekiq does not print out that line if you daemonize.

    https://github.com/mperham/sidekiq/blob/master/lib/sidekiq/cli.rb#L80