【发布时间】:2015-01-01 02:28:04
【问题描述】:
我正在尝试使用 NGINX 和 gunicorn 部署一个 django 项目。我不断收到 502 Bad Gateway。在过去的几天里,我一直在不停地工作,但我似乎无法部署它。我已经阅读了有关 Digital Ocean 的 3 个教程,但显然它们都不正确。
我不断收到 502 bad gateway,或者如果我尝试使用 manage.py runserver,我收到 400 bad request。
我认为我的问题在于 gunicorn。当我输入 gunicorn -config 时,它说
usage: gunicorn [OPTIONS] [APP_MODULE] gunicorn: error: No application module specified.
我能找到的每一点文档都说只需键入 gunicorn wsgi:application,但是当我这样做时,它会显示“workers failed to boot”。如何设置应用模块?
【问题讨论】:
标签: python django nginx gunicorn digital-ocean