Linux Gitlab:通过ssh克隆repo时,它会不断询问密码

Linux Gitlab:通过ssh克隆repo时,它会不断询问密码,linux,git,gitlab,Linux,Git,Gitlab,我已经在LINUXRHEL 6.7上安装了gitlab。在通过ssh克隆repo时,它会不断询问git的密码,但是使用http它工作正常: $ git clone http://MGJV67@il06epclin1.am.mot-solutions.com/MGJV67/NewPROJ.git Cloning into 'NewPROJ'... warning: You appear to have cloned an empty repository. mgjv67@mgjv67-430 M

我已经在LINUXRHEL 6.7上安装了gitlab。在通过ssh克隆repo时,它会不断询问git的密码,但是使用http它工作正常:

$ git clone http://MGJV67@il06epclin1.am.mot-solutions.com/MGJV67/NewPROJ.git
Cloning into 'NewPROJ'...
warning: You appear to have cloned an empty repository.

mgjv67@mgjv67-430 MINGW64 /c/TCS/Gitlab/NewPROJ (master)
$ git clone git@il06epclin1.am.mot-solutions.com:MGJV67/NewPROJ.git
Cloning into 'NewPROJ'...
git@il06epclin1.am.mot-solutions.com's password:
Permission denied, please try again.
Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights and the repository exists.

虽然可以通过http进行匿名克隆,但只能通过SSH使用有效的SSH标识进行克隆。
创建一个SSH密钥并将公钥添加到您的Gitlab用户帐户,或者将其添加为项目的部署密钥,以防您只需要只读访问。

我也上传了SSH密钥,但它仍在询问密码。