The fastest way is to change the password for the git user with root privileges.
I guess the reason may be that the permissions of the .ssh directory are too high. You must restrict access to only yourself.
Posting the reported errors may make it easier to find the problem.
You can check the auth log on the server to see if there is any information you may need
If the warehouse address is
git@your.git.host
,那么你需要在git
用户的$HOME/.ssh/authorized_keys
add your public key in it, so you don’t need a password.Clear your ~/.ssh/known_hosts
ssh-keygen ....
thenssh-copy-id -i user@server
mugbya, I encountered the same problem, how did you solve it? . . I don’t think it’s a matter of public and private keys
It should be a permissions issue. Look at the permissions of authorized_keys and pay attention to the directory
The fastest way is to change the password for the git user with root privileges.
I guess the reason may be that the permissions of the .ssh directory are too high. You must restrict access to only yourself.
Posting the reported errors may make it easier to find the problem.
You can check the auth log on the server to see if there is any information you may need
Encountered the same problem