I am trying to pull some documents from git using git clone
as part of a jenkins process. Git clone works fine separately, but as a part of jenkins, I am facing permission denied issue
> echo "pw"| sudo git clone host@IP:git-repo
> Cloning into 'git-repo'...
Permission denied, please try again.
Permission denied, please try again.
Permission denied(publickey,password).
fatal: Could not read from remote repository.
尝试使用SSH代理插件使您的私钥可以访问常规构建步骤。
Try this,
superuser ALL=(ALL) NOPASSWD:ALL - for single user
refer link
This setting help us to bypass user prompt.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.