我正在尝试使用 gunicorn 和工头运行我的 django 应用程序。我可以使用python manage.py server
. 但是,当使用 forman 运行它时,它会失败 -
15:32:01 web.1 | started with pid 29188
15:32:01 web.1 | 2012-08-16 15:32:01 [29191] [INFO] Starting gunicorn 0.14.6
15:32:01 web.1 | 2012-08-16 15:32:01 [29191] [INFO] Listening at: http://127.0.0.1:8000 (29191)
15:32:01 web.1 | 2012-08-16 15:32:01 [29191] [INFO] Using worker: sync
15:32:01 web.1 | 2012-08-16 15:32:01 [29194] [INFO] Booting worker with pid: 29194
15:32:01 web.1 | 2012-08-16 15:32:01 [29194] [INFO] Worker exiting (pid: 29194)
15:32:02 web.1 | 2012-08-16 15:32:02 [29191] [INFO] Shutting down: Master
15:32:02 web.1 | 2012-08-16 15:32:02 [29191] [INFO] Reason: Worker failed to boot.
15:32:02 web.1 | exited with code 3
以下是 Procfile 的内容 -
web: gunicorn tms.wsgi
我一直按照 heroku 上的说明进行设置。