0

I have an instance of Jenkins running in a pod in Kubernetes. I'm trying to let it connect to a local network git repository server, but I'm getting the error:

stdout: 
stderr: ssh: Could not resolve hostname {hostname}: Temporary failure in name resolution 
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

I added a private key to Jenkins because I thought that authentication was the problem, but that didn't help. I also tried getting a shell into the Jenkins pod and I pinged the {hostname} but then I get the same error Temporary failure in name resolution. If I enter the IP address directly, the ping does work. But when I enter that IP address in Jenkins instead of the {hostname}, then I get a Connection timed out error..

I'm surely missing something, but I don't know what. When I first connected to the repo (from a local machine) I had to accept a server key first, otherwise the connection failed too. Could this be the problem, maybe?

3
  • is your kubernetes in the same network where your git is? May 23, 2019 at 10:12
  • @YashJagdale Yes, I believe it is (since I can ping the IP directly). May 23, 2019 at 11:40
  • @YashJagdale Actually, no. They are not on the same network. Kubernetes is running inside a VM, and the reason that I can ping the IP is that a network adapter is using the specific range. I'll have to ask the network admin.. May 23, 2019 at 11:55

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.