gpt4 book ai didi

python - 在 openshift 上启动 Celery

转载 作者:行者123 更新时间:2023-11-28 16:38:39 25 4
gpt4 key购买 nike

我目前正在编写一个 flask 应用程序并打算使用 openshift。我使用

在我的开发环境中启动我的工作人员
celery worker -A wsgi.app

我的问题是如何在 openshift 中启动我的 celery worker?因为如果我在退出 shell 时在 openshift shell 中启动,进程将被终止并且我的后台工作人员永远不会运行,所以 flask 应用程序永远不会正确运行。我真的很感激任何帮助。谢谢。

最佳答案

为什么不能这样尝试

celery multi start worker1 \
--pidfile="$HOME/run/celery/%n.pid" \
--logfile="$HOME/log/celery/%n.log"

哪里提到了here

关于python - 在 openshift 上启动 Celery,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22497845/

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