git install in jenkins

If you want to how to install Git in Jenkins, It can be possible either by GUI or command line. I will show you through the GUI mode. Sometimes it doesn’t work when you try to install it from Jenkins plugins available. So, we would have to install it using the command line on the server and restart the Jenkins service.

How To Install Git:

When you’re done with the installation part. login to your Jenkins dashboard and copy the git repository URL from your git server. Now try to create a job and put the link and see you won’t get any issue related to the repository to fetch the data.

Why do you need git installed!

As if you’re going to create a job in Jenkins and want to pull the code
from git-hub or git-lab.

So you need to be sure there are git plugins installed in Jenkins
otherwise, you won’t be able to create a job or pull code from there.

Check Out: Jenkins HTTP 404

The Command is yum install git -y

Log in to the Jenkins server and click on “Manage Jenkins” & look for “Global Tool Configuration”.

Click on “Global Tool Configuration”.

git jenkins

Check Out: Install Maven in Jenkins

As you can see Git is not installed by default in Jenkins. you have to install it. Just
click on Install automatically and apply.

git not installed

After installing git you have to restart the Jenkins server otherwise it won’t work.
systemctl restart jenkins

Now Check git has been installed or not by creating a job in Jenkins. Get a free project from git-hub to test it.

Check Out: How To Install SQLyog 15 Version On Windows Machine

jenkins git install

As you can see Git has been installed if get any error after putting the Git repository
URL that means Git has not been installed yet you need to check it.

YouTube Link:

That’s it.

LEAVE A REPLY

Please enter your comment!
Please enter your name here