过程
- 在$GOPATH/src中新建一个project:
my_project
cd my_project
- 添加代码
git init
heroku git:remote add your_app_name
git add -A .
git commit -m "init commit"echo "web: your_app_name" >> Procfile
go get github.com/tools/godep
godep save
git add -A .
git commit -m "second commit"
git push heroku master
错误
No web processes running
$ heroku ps:scale web=1
Scaling dynos... done, now running web at 1:Free
$ heroku ps
Free dyno hours quota remaining this month: 493h 22m (89%)
For more information on dyno sleeping and how to upgrade, see:
https://devcenter.heroku.com/articles/dyno-sleeping
参考
https://mmcgrana.github.io/2012/09/getting-started-with-go-on-heroku.html