将 rails 部署到 heroku - 未经授权的公钥访问 [英] deploying rails to heroku - unauthorized public key access
问题描述
所以我试图将我的应用程序部署到 heroku,但是每当我推送到 master 时它总是给我这个错误:
So I'm trying to deploy my app to heroku but it keeps giving me this error whenever I push to master:
<代码>!您带指纹的密钥 cb:e1:5c:31:cd:6b:78:6e:30:ff:eb:11:e2:4b:2e:b3 无权访问 smooth-mountain-8970.
我尝试了从生成新的 ssh 密钥到删除所有内容和替换文件的所有方法.我什至创建了一个不同的用户名并尝试上传,但它一直给我这个错误,认为我想上传到平滑山,而事实上,我的应用程序名称不是平滑山.大家知道可能是什么问题吗?
I tried everything from generating new ssh keys to deleting everything and replacing the files. I even created a different username and tried uploading, but it keep giving me this error thinking that I want to upload to smooth-mountain when in fact, my app name is NOT smooth-mountain. Do you guys know what the problem might be?
谢谢.
推荐答案
ssh-agent
(一个保存用于公钥认证的私钥的程序)自 Mac OS X Leopard 起自动运行.要解决您的问题,您必须通过发出以下命令从代理中删除身份.
ssh-agent
(a program that holds private keys used for public key authentication) runs automatically since Mac OS X Leopard. To resolve your problem you must remove identities from the agent by issuing the following command.
ssh-add -d
示例:
> ssh-add -l
1024 a3:d5:21:2d:50:ee:3e:af:1b:44:62:60:1d:e4:51:21 /Users/bart/.ssh/id_dsa (DSA)
> ssh-add -d
Identity removed: /Users/bart/.ssh/id_dsa (/Users/bart/.ssh/id_dsa.pub)
> ssh-add -l
The agent has no identities.
这只会暂时从此会话中删除密钥.就个人而言,我不介意偶尔这样做.但是,如果您想永久禁用 ssh-agent,请参阅:SSH Key禁用缓存
This will only remove the keys from this session temporarily. Personally, I don't mind doing this once in a while. However, if you would like disable ssh-agent permanently, see: SSH Key Disable Caching
这篇关于将 rails 部署到 heroku - 未经授权的公钥访问的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!