我是heroku和gunicorn的新手,所以我不确定这是如何工作的.但我已经做了一些搜索,我认为我已接近部署我的Django应用程序(1.5.1).所以我知道我需要一个具有的Procfile
web: gunicorn app.wsgi
Run Code Online (Sandbox Code Playgroud)
因为我的目录有点不同.我无法在根目录中运行gunicorn
app_project
requirements/
contributors/
app/
app/
settings/
wsgi.py
# Normally Procfile goes here
Procfile
Run Code Online (Sandbox Code Playgroud)
通常app /将是根目录,但我决定以这种方式构建我的文件夹以将我的django应用程序与其他一些东西分开.由于我必须将Procfile放在根目录中以便heroku识别它,我应该在Procfile中放入什么和/或我应该在gunicorn命令中放置什么参数?
注意:
web: gunicorn app.wsgi # won't work because Procfile is in a directory above
# I also want to keep the directories as is
# I also don't want to create a secondary git inside the app folder just for heroku
web: gunicorn app.app.wsgi # won't work because I don't want to convert the folder into a python module
Run Code Online (Sandbox Code Playgroud)