【问题标题】:Heroku with Multiple Domains具有多个域的 Heroku
【发布时间】:2026-01-15 02:25:01
【问题描述】:

我有多个 Heroku 域。在我创建了一个新的并推送后,它会检查第一个的 rsa。

如何处理?谢谢。

203-96:first_app marklaudauw$ heroku create 创建 serene-chamber-4301... 完成,堆栈是 cedar http://serene-chamber-4301.herokuapp.com/ | git@heroku.com:serene-chamber-4301.git

203-96:first_app marklaudauw$ git push heroku master

!您的指纹为 98:6b:fe:d4:e3:0a:17:16:ab:f8:11:18:a2:66:76:b6 的密钥无权访问 glacial-shelf-8147。

致命:远端意外挂断

【问题讨论】:

  • 检查heroku日志,它将显示导致错误的原因。还要确保在部署代码之前完整阅读 heroku 文档

标签: ruby-on-rails git heroku github


【解决方案1】:

在推送之前试试这个:-

$ git remote add heroku git@heroku.com:yourappname.git  ( to add current stack )

$ heroku keys:add ~/.ssh/id_rsa.pub (if stuck with key then add local machine key to heroku) 

$ git commit -m "message"

$ git push heroku master <branch name>

【讨论】:

    【解决方案2】:

    我设法通过以下命令解决了它:

    git 远程 rm heroku

    git 远程添加 heroku git@heroku.com:serene-chamber-4301.git

    谢谢...

    【讨论】: