官网及下载
Jenkins官方网站:http://jenkins-ci.org ,可直接到官网手动下载安装。
下面直接通过yum命令安装:
Recent versions are available in a YUM repository.
Installation
Add the Jenkins repository to the yum repos, and install Jenkins from here.
sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo
sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
sudo yum install jenkins
Installation of a stable version
There is also a LTS YUM repository for the LTS Release Line
sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat-stable/jenkins.repo
sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
sudo yum install jenkins
Installation of Java
Jenkins requires Java in order to run, yet certain distros don't include this by default. To install the Open Java Development Kit (OpenJDK) run the following:
sudo yum install java
Note: If running CentOS, ensure you follow the guide below.
Start/Stop
sudo service jenkins start/stop/restart
sudo chkconfig jenkins on
Note: if you get the following error message, ensure that Java has been installed: