Restart single process with Foreman

夙愿已清 提交于 2019-12-22 08:21:44

问题


I've been using foreman for a while now to scale my various ruby processes in a centralized manner, and it is working perfectly for me .

Anyways I would like to have some feature to restart a process or even to give it more control like to kill a process and start it again, in the current implementation when I kill one process the whole process in the main foreman stop . any workaround or solution here ?

Thanks in advance


回答1:


While foreman start is very convenient for development, I would not recommend it for production. I recommend using upstart, but there are also other alternatives - foreman also supports exporting to bluepill, inittab and runit (I've never used any of these myself).

I've also used god in the past, and it worked quite well for starting and monitoring processes. I wrote a foreman_god gem to use Procfiles with god, which simplifies the configuration (no need to export any config files).

Alternatively, there is also an export script that exports god config files from your Procfile.




回答2:


It seems that answer within the fork of John Mosses foreman_restartable , https://github.com/jmoses/foreman



来源:https://stackoverflow.com/questions/8587588/restart-single-process-with-foreman

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