簡體   English   中英

Jenkins(Windows)無法通過git(Linux)存儲庫克隆

[英]Jenkins(Windows ) unable to clone through git(Linux) repository

設置詳細信息:

Windows 10上的JENKINS

GIT插件設置完成

公私鑰設置完成

通過CMD克隆存儲庫 通過CMD克隆存儲庫

通過Jenkins進行git clone失敗並出現以下錯誤

"C:\Program Files (x86)\Jenkins\workspace\Aclselenium>git clone rahulp@10.0.6.194:/Operations/repo/git/test.git 
Cloning into 'test'...
Permission denied, please try again.
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."

JENKINS控制台日志

通過Windows cmd在命令下方運行

"whoami" command gives > "acl-wireless\rahulp"

"echo %USERNAME%" command gives `> "rahulp"`

當我通過JENKINS運行以上命令時,我收到:

"whoami" command gives > "nt authority\system"

"echo %USERNAME%" command gives `> "RAHULPANDEY$ RAHULPANDEY$"`

你的命令行訪問git和你jenkins獲得git是兩個不同的東西。 在命令行中,將為您提供usernamepassword進行登錄。 但是您需要從jenkins配置憑據。 轉到Manage Jenkins => Configure System => GitHub然后在此處提供憑據。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM