我正在学习这个教程(https://devcenter.heroku.com/articles/getting-started-with-python),学习如何使用Heroku。这是我的问题:
1)完成了部署应用程序的典型操作:
$ heroku create
$ git push heroku master
$ heroku ps:scale web=1
$ heroku ps具体过程如下:
== web (1X): 'gunicorn hello:app'Procfile中的文本为"web: gunicorn hello:app“。文件夹svm中的文件/目录:
svm
--hello.py
--hello.pyc
--Procfile
--requirements.txt
--svm.py
--svm.pyc
--venv2)现在,我已经在同一个文件夹中创建了一个新的python文件,比如svm.py。我已经将procfile从"web: gunicorn hello:app“更改为"web: gunicorn svm:app”。
$ git add .
$ git push heroku master
$ heroku ps:scale web=0
$ heroku ps:scale web=1
$ heroku ps但出于某种原因,我还是得到了:
=== web (1X): 'gunicorn hello:app'我如何改变这一点,以反映我现在想要使用svm.py而不是hello.py的事实?
发布于 2014-01-05 05:03:16
@Nitzan你的回答很有效,而且,事实证明,我还必须用这里概述的细节来补充我的heroku构建:Deploy matplotlib on heroku failed. How to do this correctly?
https://stackoverflow.com/questions/20918579
复制相似问题