【发布时间】:2013-11-04 23:49:35
【问题描述】:
我正在尝试从 github.com 将私有 repo 签出到我在 EC2 上的开发实例上。
$ git clone git@github.com:Org/Product.git
Initialized empty Git repository in /home/ec2-user/Product/.git/
Permission denied (publickey).
fatal: The remote end hung up unexpectedly
我该怎么做?我也尝试了 SSH 转发,但没有成功。
【问题讨论】:
-
您是否正确设置了 SSH 密钥?
-
我不确定,你能告诉我要检查什么来验证吗?
-
尝试运行
ssh -v git@github.com。您应该从 github 收到一条带有您的用户名的消息,但如果有问题,您可能不会收到。 -v 将为您提供详细的输出,以帮助您查看 ssh 正在做什么并可能跟踪问题。
标签: git ssh amazon-ec2