Jenkins CI server installation on CentOS 7

Jenkins is nice CI tool and is easy to install and setup it. Below are steps for CentOS 7, assuming you have already Centos 7 installed and able to connect to internet, do below in order to get Jenkins server installed and running

Get Jenkins repository information and upload key

wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat-stable/jenkins.repo
rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key

Install packages and open Jenkings port

yum install java-1.7.0-openjdk
systemctl start jenkins
systemctl enable jenkins
firewall-cmd --zone=public --add-port=8080/tcp --permanent
firewall-cmd --zone=public --add-service=http --permanent
firewall-cmd --reload

After this you can access jenkins web interface via http://server_hostname:8080, where server_hostname should be $(hostname -s).
Further tweaking might be directed toward Manage Jenkins -> and pick up what you want to change. Installing some plugins – like git ones related can be helpful. rpm -ql jenkins will give list of files which are part of jenkins package installed in step above from where you can investigate it further – and eventually change some default parameters ( check /etc/sysconfig/jenkins for details )

Advertisements

#centos, #ci, #continious-integration, #jenkins, #linux