【发布时间】:2020-06-18 01:59:05
【问题描述】:
我正在升级到我们使用 monit 的 sidekiq6。由于 sidekiq6 不支持 PID(https://github.com/mperham/sidekiq/wiki/Deployment#running-your-own-process) 文件,我试图停止使用 https://github.com/ajgon/opsworks_ruby/blob/master/templates/default/sidekiq.monitrc.erb。
它不会在 monit stop/restart 等时停止。
[PST Mar 5 04:11:01] info : 'sidekiq_cric-1' trying to restart
[PST Mar 5 04:11:01] info : 'sidekiq_cric-1' stop: /bin/su
[PST Mar 5 04:12:31] error : 'sidekiq_cric-1' failed to stop
[PST Mar 5 04:12:31] info : 'sidekiq_cric-1' restart action done
如果我在控制台上运行以下操作,它会终止工作。
stop program = "/bin/su - deploy -c 'ps -ax | grep "bundle exec sidekiq" | grep sidekiq_1.yml| | grep -v grep | awk "{print \$1}" | xargs --no-run-if-empty pgrep -P | xargs --no-run-if-empty kill'" with timeout 90 seconds
请让我知道我在这里犯了什么错误......
【问题讨论】:
标签: sidekiq aws-opsworks monit