在Fedora 33中,使用ssh id_rsa文件的git操作在GitLab.com上失败



由于我安装了Fedora 33,GitLab.com上的任何git操作(以及另一个症状azure(都会失败。在GitLab.com上我得到:

git@gitlab.com: Permission denied (publickey,keyboard-interactive).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.

Azure只需询问密码,不会显示任何错误。

如中所述,gitlab的修复方法是将这些行保存在~/.ssh/config文件中:

Host gitlab.com
HostName gitlab.com
PreferredAuthentications publickey
IdentityFile ~/.ssh/id_rsa
PubkeyAcceptedKeyTypes=+ssh-rsa

对于Azure,将两次出现的gitlab.com更改为ssh.dev.azure.com

最新更新