安装 Jenkins:

1
2
3
4
5
sudo wget -O /etc/yum.repos.d/jenkins.repo \
https://pkg.jenkins.io/redhat-stable/jenkins.repo
sudo rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io.key
sudo yum makecache
sudo yum install jenkins java-1.8.0-openjdk-devel

解决安装插件太慢的的问题:

1
2
3
cd /var/lib/jenkins/updates

sed -i 's/http:\/\/updates.jenkins-ci.org\/download/https:\/\/mirrors.tuna.tsinghua.edu.cn\/jenkins/g' default.json && sed -i 's/http:\/\/www.google.com/https:\/\/www.baidu.com/g' default.json

进行初始化安装,初始密码(也是 admin 密码)在 /var/lib/jenkins/secrets/initialAdminPassword

1
http://ip:8080