Jenkins failed to set git

0 votes

I have a problem with jenkins, setting "git", shows the following error:

Failed to connect to repository : Command "git ls-remote -h https://person@bitbucket.org/person/projectmarket.git HEAD" returned status code 128:

stdout:

stderr: fatal: Authentication failed

I have tested with ssh:

git@bitbucket.org:person/projectmarket.git

This is error:

Failed to connect to repository : Command "git ls-remote -h git@bitbucket.org:person/projectmarket.git HEAD" returned status code 128:

stdout:

stderr: Host key verification failed.

fatal: The remote end hung up unexpectedly

I’m not sure what I’m supposed to do next

Jul 19, 2018 in Jenkins by Nilesh
• 7,050 points
5,222 views

1 answer to this question.

0 votes

Change to the jenkins user and run the command manually:

git ls-remote -h git@bitbucket.org:person/projectmarket.git HEAD

You will get the standard SSH warning when first connecting to a new host via SSH:

The authenticity of host 'bitbucket.org (207.223.240.181)' can't be established.
RSA key fingerprint is 97:8c:1b:f2:6f:14:6b:5c:3b:ec:aa:46:46:74:7c:40.
Are you sure you want to continue connecting (yes/no)?

Type yes and press Enter. The host key for bitbucket.org will now be added to the ~/.ssh/known_hosts file and you won't get this error in Jenkins anymore.

This helped me, I hope it helps you as well

answered Jul 19, 2018 by Kalgi
• 2,680 points

Related Questions In Jenkins

0 votes
1 answer
0 votes
2 answers

Error Jenkins: Failed to connect to repository

Jenkins runs as another user, not as ...READ MORE

answered Aug 7, 2019 in Jenkins by Sirajul
• 59,230 points
10,126 views
0 votes
5 answers

How to resolve this error “Jenkins Host key verification failed”?

HI Mam, Please check the following solution:: 1. Switch ...READ MORE

answered May 3, 2019 in Jenkins by anonymous
59,808 views
0 votes
2 answers

where to set the context path - jenkins

Put this into /etc/apache2/other/jenkins.conf: ProxyPass ...READ MORE

answered Aug 10, 2018 in Jenkins by Nilesh
• 7,050 points
7,914 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
3,439 views
+2 votes
1 answer
0 votes
1 answer

How to rebuild an item on Jenkins pipeline

Yes you can, its pretty simple actually. Go ...READ MORE

answered Jul 10, 2018 in Jenkins by Kalgi
• 2,680 points
3,840 views
0 votes
1 answer

How do I pass value from my Fake # script to the host build server (Jenkins)

You can use the EnvInject plugin to pass environment ...READ MORE

answered Jul 11, 2018 in Jenkins by Kalgi
• 2,680 points
1,137 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP