Search code examples
ruby-on-railssidekiq

Where to define worker inside a gem


I am writing a gem. I would like the calls to the gem's api to trigger calls to some Sidekiq workers. Where do I write these workers inside my gem so Sidekiq finds them even though they are not in 'app/workers'?


Solution

  • It's hard to answer without knowing exactly what you are doing.

    However I'd say that adding a procfile that people installing your gem can use would work.

    Ref https://github.com/ddollar/foreman