环境
- [x] CentOS Linux release 8.1.1911 (Core)
- [x] Jenkins-2.222.3-1.1
安装
升级系统
shell > dnf update -y

安装JAVA
shell > dnf install -y java-1.8.0-openjdk

shell > java -version

添加Jenkins存储库
shell > dnf install -y wget

shell > wget -O /etc/yum.repos.d/jenkins.repo https://pkg.jenkins.io/redhat-stable/jenkins.repo

shell > rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io.key
在CentOS 8 / RHEL 8系统上安装Jenkins
shell > dnf install -y jenkins

这里我安装速度非常慢,所以我使用的是清华大学的RPM
shell > dnf install -y https://mirrors.tuna.tsinghua.edu.cn/jenkins/redhat-stable/jenkins-2.222.3-1.1.noarch.rpm
启动并启用Jenkins服务
shell > systemctl start jenkins
shell > systemctl enable jenkins
shell > systemctl status jenkins

配置防火墙
shell > firewall-cmd --zone=public --permanent --add-port=8080/tcp
shell > firewall-cmd --reload

设置詹金斯
浏览器访问Jenkins,地址为:服务器IP:8080

提示输入密码,密码在页面提示的文件里
cat /var/lib/jenkins/secrets/initialAdminPassword


安装建议的插件


添加管理员账户

配置默认访问地址

开始使用

