在linux系统下搭建git服务器,在自己电脑克隆,一直显示输入密码?
PHP中文网
PHP中文网 2017-05-02 09:22:40
0
8
760

在linux centos 6.5系统下搭建git服务器,也复制了公钥到authorzied_keys文件中,在自己电脑上克隆线上的文件,

,一直提示输入密码,各种密码都输入,也都不正确,不知道是哪配置错了,求高手帮我看下。是什么问题导致的?

PHP中文网
PHP中文网

认证0级讲师

reply all(8)
我想大声告诉你

Check if there is this stuff under your /home/git/.ssh/: authorzied_keys
Maybe it’s a permission issue?

There are many situations, but the information you gave is quite little

習慣沉默

The authorized_keys of the git user cannot be directly pasted into the pubkey. . .
The authorized_keys file requires some additional instructions to ensure the normal working of git

What git server did you install? Read the instructions of git server carefully and redeploy the pubkey

巴扎黑

You need to upload your own key. The method may be different depending on the git server. For example, in gitolite, the administrator needs to put the key you generated in the keydir directory of gitolite-admin

小葫芦

.ssh 700
authorized_keys 600
Check it and make sure the usernames are consistent

phpcn_u1582

In your case, it should be an account problem. Please check the following method: create the git user on the git server and set a password, then chown the permissions of the git server directory to the git user, and finally su git使用git帐户登陆,并ssh-keygen生成.ssh目录,最后在启动git服务端!如果有web端,可以通过web方式加key,没有web端的要手动加入key到/home/git/.ssh/authorized_keys

曾经蜡笔没有小新

It seems that the client of the question is on windows. The questioner tries to enable it Pageant并把相应的.ppk and add it. This tool should be included when TortoiseGit is installed.

仅有的幸福

Look at /etc/passwd to see if the corresponding shell for the git user is git-shell

When I first wrote no-longin, it prompted protocol error: bad line length character: This

When writing /usr/bin/git-login, I keep being prompted to enter the password, and no matter how I enter it, it is wrong.

It will be fine until it is changed to /usr/bin/git-shell.

伊谢尔伦

Reset git password on the server: passwd git

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!