首页 > 解决方案 > 如何在 ssh aws ec2 实例之后保持 gunicorn flask 应用程序运行

问题描述

我是服务器和应用程序的新手。

目前,我已经在我的 aws 实例上创建了一个应用程序。

gunicorn --threads 4 -b 0.0.0.0:5000 --access-logfile server.log --timeout 60 server:app

但是我想在我 ssh 实例后让它继续运行,我怎么能做到这一点?

[2018-09-24 17:45:28 +0000] [8318] [INFO] Starting gunicorn 19.9.0
[2018-09-24 17:45:28 +0000] [8318] [INFO] Listening at: 
 http://0.0.0.0:5000 (8318)
[2018-09-24 17:45:28 +0000] [8318] [INFO] Using worker: threads
[2018-09-24 17:45:28 +0000] [8321] [INFO] Booting worker with pid: 8321

我现在也必须使用 control+c 退出。

标签: amazon-web-servicesflaskgunicorn

解决方案



推荐阅读