Renamed Heroku's hostname, now it can't find the application

梦想与她 提交于 2019-12-03 16:32:09

问题


I previously had my Heroku's application name at:

shielded-meadow-9293.heroku.com

This was the name when I created the Heroku remote and fired up the dyno. After everything was running smooth, I changed the name to

platformdesignmadness.heroku.com

The site works, but in the same terminal, when I do a command such as

heroku ps

I get a $> ! Couldn't find that app. error. Why is this?


回答1:


In your terminal:

git remote rm heroku
git remote add heroku git@heroku.com:yourappname.git

See here

Heroku docs here.




回答2:


For all the people showing up here trying to figure out why a

$ heroku run:detached python script.py -n yyy -a zzzz

command isn't working, and giving this error:

▸    Couldn't find that app.

it's because Heroku senses the -a argument as the app name. To ignore these the fix is this, basically adding a --:

$ heroku run:detached -- python script.py -n yyy -a zzzz

and now it will work properly.



来源:https://stackoverflow.com/questions/23160131/renamed-herokus-hostname-now-it-cant-find-the-application

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!