Gobblin Git克隆错误

时间:2016-01-04 05:32:58

标签: linux git github amazon-ec2

尝试从git clone下载并构建Gobblin时。通过跟踪,在本地下载和构建Gobblin 在本地计算机上,克隆Gobblin存储库:

git clone git@github.com:linkedin/gobblin.git

它在我的Amazon Ec2实例中出现以下错误。

$ git clone git@github.com:linkedin/gobblin.git
Cloning into 'gobblin'...
Warning: Permanently added the RSA host key for IP address '192.30.252.131' to the list of known hosts.
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights and the repository exists.

如何避免该错误消息?

1 个答案:

答案 0 :(得分:0)

问题不在于与地精服务器通信,而是在ec2实例和github.com之间进行通信(通过ssh)

执行ssh命令(或git clone ssh)时,ssh将在ec2用户帐户$HOME/.ssh文件夹中查找公钥/私钥。

确保您已关注" Generating SSH keys"为了在您的EC2帐户中生成正确的密钥,并在您的GitHub帐户上声明公钥。

另一种方法是切换到https:

git clone https://github.com/linkedin/gobblin.git