gpt4 book ai didi

uwsgi - 如何使用管理员启动/停止uWSGI应用程序?

转载 作者:行者123 更新时间:2023-12-03 13:16:04 30 4
gpt4 key购买 nike

我使用主管来运行uWSGI应用程序。为什么uWSGI应用程序在停止主管后并不总是停止?
主管配置:

[program:test]
autostart = true
user=root
command=uwsgi --master --workers 5 --disable-logging --socket 127.0.0.1:8888
--module web --callable app
priority=1
redirect_stderr=true
stdout_logfile = /data/log

最佳答案

默认情况下,主管在停止时发送SIGTERM。 uWSGI中的SIGTERM表示“残酷的重新加载”。

您必须将其更改为QUIT或INT:

stopsignal =退出

应该足够了

另一种方法(建议使用)是在uWSGI命令行中添加--die-on-term来更改其默认行为

关于uwsgi - 如何使用管理员启动/停止uWSGI应用程序?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19510195/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com