开发者

Starting delayed_job with max-priority on Heroku using procfile

How can I pass the --max-priority parameter to delayed_job using a procfile?

On my EC2 server I could pass the --max-priority parameter when starting delayed_job like so:

script/delayed_job start --max-priority 5

I'm now trying to migrate to Heroku using their cedar stack and still need the --max-priority param, but that same line fails when used in the procfile. According to the log this is because Heroku doesn't allow access to /tmp which is needed by delayed_job when started with script/delayed_job.

Is there another way to use a procfile to start delayed_job AND p开发者_运维知识库ass max-priority?


I know this is an old question

You can specify multiple worker types in your Procfile

worker:      bundle exec rake jobs:work
worker-low:  bundle exec rake jobs:work MAX_PRIORITY=5

Now you can scale each worker type independently;

heroku ps:scale worker=1 worker-low=10
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜