Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
+1 vote
2 views
in DevOps and Agile by (29.3k points)

I need some help here, I can't figure out what's going on. I'm not able to clone a git repo from a slave node (Jenkins). I added the ssh key, host and slave (I've already tried generating a single key and one for each virtual and host)).

On Jenkins:

url:[email protected]: < repo>

Credentials: Here I tried with username/password, username with ssh file, username with ssh key directly, and -none-.

It doesn't seem like there is an authentication problem since I can clone the repo manually from console (both, slave and host). I can also connect with

ssh -T [email protected]

so the ssh key is fine, but when I build, this appears on the console:

Building remotely on IE10Win7 in workspace C:\Users\IEUser\Desktop\< folder >

Wiping out workspace first.

Cloning the remote Git repository

Cloning repository [email protected]:< repo>.git

git init C:\Users\IEUser\Desktop\< folder> # timeout=10

ERROR: Error cloning remote repo 'origin'

ERROR: Error cloning remote repo 'origin'

Performing Post build task...

Does anyone have an idea? Hope someone can give me a clue, Thanks!

1 Answer

0 votes
by (50.2k points)

To fix this problem you need to set the slave node tool path, selecting git and setting its value to

C:\Program Files (x86)\Git\bin\git.exe

Location: Configure Node - Tool Locations. This will help you to resolve this particular issue instead of changing global configurations of Jenkins.

Browse Categories

...