【发布时间】:2015-11-04 06:50:32
【问题描述】:
我最近刚刚将我的 phoenix 应用程序更新到 0.16.0。我正在关注与deployment 相关的文档。
到目前为止,一切都比较顺利。 phoenix 文档告诉您设置一个新贵脚本:
description "test phoenix app"
## Uncomment the following two lines to run the
## application as www-data:www-data
setuid phoenix
setgid phoenix
start on runlevel [2345]
stop on runlevel [016]
expect stop
respawn
env MIX_ENV=prod
export MIX_ENV
## Uncomment the following two lines if we configured
## our port with an environment variable.
#env PORT=8888
#export PORT
## Add app HOME directory.
env HOME="/home/phoenix"
export HOME
pre-start exec /bin/sh /test_app/bin/test_app start
post-stop exec /bin/sh /test_app/bin/test_app stop
此脚本成功启动应用程序,但是当我运行时
initctl stop phoenix upstart 告诉我它已经停止了 phoenix,但是在运行 ps aux|grep phoenix 之后,我可以看到应用程序仍在运行,服务器仍在 localhost:4000 返回 200。
我很困惑!
【问题讨论】:
标签: ubuntu upstart phoenix-framework