首页 > 其他 > 详细

git:could not open a connection to your authentication agent

时间:2018-08-24 12:38:22      阅读:133      评论:0      收藏:0      [点我收藏+]

git:could not open a connection to your authentication agent

?

错误:

vagrant@homestead:~/Code/sample$ git push -u origin master

git@github.com: Permission denied (publickey).

?

fatal: Could not read from remote repository.

?

Please make sure you have the correct access rights

and the repository exists.

?

?

先执行 ?eval `ssh-agent` ?

再执行 ssh-add ~/.ssh/rsa

?

上面有可能会找不到路径

?

vagrant@homestead:~/Code/sample$ ssh-add ~/.ssh/id_key

/home/vagrant/.ssh/id_key: No such file or directory

切换到秘钥目录在执行就行了

?

?

vagrant@homestead:~$ cd .ssh/

?

vagrant@homestead:~/.ssh$ ssh-add ~/.ssh/id_rsa

?

?

成功:Identity added: /home/vagrant/.ssh/id_rsa (/home/vagrant/.ssh/id_rsa)

?

?

?

文章来源:刘俊涛的博客

欢迎关注,有问题一起学习欢迎留言、评论。

git:could not open a connection to your authentication agent

原文:https://www.cnblogs.com/lovebing/p/9528974.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!