CI / CD has been very popular lately and Jenkins is just one of the CI tools. There are two ways to install Jenkins, one is to download the .war file directory, another way is to install through yum. In this post, I will use the later way.
Install jenkins’s repository file follow by install jenkins and java.
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 yum install jenkins java
Start Jenkins service.
systemctl start jenkins systemctl status jenkins
Jenkins use 8080 port by default, we can double check by using
You need to make sure port 8080 is accessible. For simplicity, I will stop firewalld for now. For more information about firewalld, please refer: CentOS7 firewall-cmd Cheat Sheet
systemctl stop firewalld
Now use browser to open Jenkins. Type in
As suggested, admin password can be found at
After passwd is enter, now we start to install plugins.
After plugins installation, we can decide to create a new user or continue as admin. For simplicity, I will continue as admin.
Last step is to save the configuration.
Once clicked on start using jenkins, you are in Jenkins!