用新電腦克隆 gitlab 上的倉(cāng)庫(kù)時(shí),報(bào)了 Permission denied 的錯(cuò)誤:
git clone ssh://git@xxx/CHARLEY-FE/ICB_MONITOR.git
Cloning into 'ICB_MONITOR'...
git@xxx's password:
Permission denied, please try again.
git@xxx's password:
Permission denied, please try again.
git@xxx's password:
git@xxx: 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.
我已經(jīng)在本地生成了公私鑰文件辛藻,但在克隆倉(cāng)庫(kù)時(shí)報(bào)錯(cuò)者疤。在網(wǎng)上找到了原因,這是因?yàn)槲以谏晒€時(shí)使用了自定義的名稱而不是 id_rsa 和 id_rsa.pub阔籽,于是我將生成的密鑰文件進(jìn)行改名流妻,再克隆,就可以了笆制。
完绅这。