Rails Heroku Sidekiq Confirm Procfile is Working

こ雲淡風輕ζ 提交于 2019-12-07 08:15:19

问题


I have set my Procfile in the root of my app:

web: bundle exec thin start -p $PORT
worker: bundle exec sidekiq -c 5 -v

and I can see that heroku sees it when I push my rails app up via git push heroku master

Procfile declares types      -> web, worker

The problem is that a bunch of jobs are just getting stuck in the "enqueue" section.

If I run heroku run bundle exec sidekiq from the command line, only then will the jobs process.

Any ideas on how I could debug this? Thanks!


回答1:


Have you started worker dynos? Heroku will only start the web process type automatically for you. Check the output of heroku ps - you'll probably only see your web process listed.

You would need to do;

 heroku ps:scale worker=1

to add a worker dyno and scale it to 1.



来源:https://stackoverflow.com/questions/16687083/rails-heroku-sidekiq-confirm-procfile-is-working

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!