我无法让我的Dyno运行多个延迟作业工作进程。
我的Procfile文件如下:
worker: bundle exec script/delayed_job -n 3 start
我的delayed_job
脚本是由gem提供的默认脚本:
#!/usr/bin/env ruby
require File.expand_path(File.join(File.dirname(__FILE__), '..', 'config', 'environment'))
require 'delayed/command'
Delayed::Command.new(ARGV).daemonize
当我尝试在本地或Heroku dyno上运行时,它会默默退出,我无法知道发生了什么。foreman start
16:09:09 worker.1 | started with pid 75417
16:09:15 worker.1 | exited with code 0
16:09:15 system | sending SIGTERM to all processes
SIGTERM received
无论是如何调试问题还是关于在单个dyno上运行多个worker的其他建议,都将非常感激任何帮助。