在 Heroku 上重新定义 Rails 应用
我有一个曾经在heroku 上的rails 项目。由于某种原因,我无法再访问 heroku url 上的那个 Rails 项目。更新到 Rails 3 后,我决定为该应用程序获取一个新的 URL。我该怎么办?
我尝试了以下
# in the rails directory...
git remote rm heroku
heroku create
git push heroku master
错误:
! No such app as generated-heroku-subdomain
,其中generated-heroku-subdomain 可以替换为我运行此命令时生成的名称。
I have a rails project that was once on heroku. For some reason, I cannot access that rails project on the heroku url anymore. After updating to Rails 3, I decided to get a new URL for the app. How do I go about this?
I have tried the following
# in the rails directory...
git remote rm heroku
heroku create
git push heroku master
Error:
! No such app as generated-heroku-subdomain
Where generated-heroku-subdomain
can be replaced by the names generated from any time I ran this.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您是否在 Heroku 网站的 myapps 下查看过您的应用程序是否仍在列出?如果是,您将在应用程序页面底部看到一个 git REPO url,然后您可以使用它将其读取为项目代码中的远程 URL。
另外,检查 git Remote -v 的响应以确保未引用旧应用程序名称。
Have you looked on the Heroku site under myapps to see if your application is still listed? If it is you'll see a git REPO url at the bottom of the applications page, you can then use this to readd it as a remote URL in your project code.
Also, check the response of git remote -v to make sure the old application name isn't being referenced.
您还可以删除存储库并再次添加。
一切都应该很好。
You can also remove your repo and add it again.
And all should be good.