How to start delayed job workers in production mode

邮差的信 提交于 2019-12-06 01:59:43

问题


I was following railscast for delayed job. Things are working perfectly on my machine. How can start delayed_job workers in production mode?

I am using delayed_job gem,(2.1.4)


回答1:


RAILS_ENV=production script/delayed_job start

For Rails 4

RAILS_ENV=production bin/delayed_job start

Solved my problem.

It may give you an error that tmp directory doesn't exists. Just create one and run previous command again..




回答2:


You can try to run the following command:

RAILS_ENV=production cd ~/path_to_your_app/current && /usr/local/bin/ruby ./script/delayed_job start

where you should adjust /usr/local/bin/ruby based on your production server ruby configuration.



来源:https://stackoverflow.com/questions/6814517/how-to-start-delayed-job-workers-in-production-mode

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