【问题标题】:How to get uwsgi container to restart with AWS EC2 reboot如何通过 AWS EC2 重启让 uwsgi 容器重启
【发布时间】:2012-12-27 17:26:40
【问题描述】:

我在我的 CentOS EC2 实例上安装了 nginx 和 uwsgi。

当我从 AWS 控制面板重启机器时,Nginx 成功重启。

Uwsgi 没有。

我必须登录并使用“sudo /etc/init.d/uwsgi start”重新启动它,然后一切正常。然后我当然可以注销,因为它正在作为服务运行。

必须登录才能完成重启过程显然不是最佳选择。

但我认为我已经正确完成了配置。

当我执行 chkconfig 时,我看到:

uwsgi           0:off   1:off   2:on    3:on    4:on    5:on    6:off

如果我查看 /etc/init.d/uwsgi 中的文件,文件顶部会显示:

#!/bin/bash
# uwsgi - Use uwsgi to run python and wsgi web apps.
#
# chkconfig: 2345 85 15
# description: Use uwsgi to run python and wsgi web apps.
# processname: uwsgi

感谢您的帮助。

【问题讨论】:

    标签: amazon-ec2 centos uwsgi


    【解决方案1】:

    使用Supervisor to control uwsgi 通常是推荐的解决方案。

    【讨论】:

      猜你喜欢
      • 2017-09-04
      • 1970-01-01
      • 2019-06-26
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-09-16
      • 1970-01-01
      相关资源
      最近更新 更多