SSH Git无需每次输入密码 [英] SSH Git without having to type in my password every time
本文介绍了SSH Git无需每次输入密码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在我的网站上设置了一个可以通过ssh访问的git repo,但是每次我将一些文件推送到repo时,我必须再次输入我的密码。有没有办法让我只需输入一次密码?
是的,你必须把你的SSH公开您可以在〜/ .ssh / authorized_keys
文件中找到您的服务器上的密钥。 你的本地机器在〜/ .ssh / id_rsa.pub
文件中(假设你在Unix系统上,我不知道这个密钥在Windows上的位置) 。
I have a git repo set up on my website which can be accessed by ssh, but every time I push some files to the repo I have to type in my password again. Is there a way in which I only have to type my password in once?
解决方案
Yes, you have to put your SSH public key on your server, in the ~/.ssh/authorized_keys
file.
You can find your public key on your local machine, in the ~/.ssh/id_rsa.pub
file (supposing you are on a Unix system, I don't know the location of this key on Windows).
这篇关于SSH Git无需每次输入密码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文