Tuesday, September 6, 2016

Installing jenkins on centos

Jenkins provides continuous integration services for software development. It is a server-based system running in a servlet container such as Apache Tomcat. It supports SCM tools including AccuRev, CVS, Subversion, Git, Mercurial, Perforce etc.

Builds can be started by various means, including being triggered by commit in a version control system, by scheduling via a cron-like mechanism, by building when other builds have completed, and by requesting a specific build URL.

There are two basic ways to install Jenkins on CentOS: through a repository, or repo, and via the WAR file. Installing from a repo is the preferred method, and it's what we'll outline here.

You'll need Java to run Jenkins (either method), so if your server doesn't yet have Java, install it with:

sudo yum -y install java
Now, run the following to download Jenkins from the Red Hat repo:

sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo
Then, import the verification key using the package manager RPM:

sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
Finally, install Jenkins by running:

sudo yum install jenkins

Now you can start Jenkins using the service command:

sudo service jenkins start 
Jenkins will now be running on the default port of 8080 (http://localhost:8080/).  localhost should be replaced by your server IP or domain name.

 


No comments: