1) 安装步骤
# yum安装
wget -O /etc/yum.repos.d/jenkins.repo https://pkg.jenkins.io/redhat-stable/jenkins.repo --no-check-certificate
rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io.key
# 备用
# wget -O /etc/yum.repos.d/jenkins.repo https://pkg.jenkins.io/redhat-stable/jenkins.repo
# rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io-2023.key
备注: 高版本的Jenkins只支持JDK11,JDK17,JDK21
yum install -y jenkins
systemctl daemon-reload
systemctl enable jenkins
systemctl start jenkins
# 访问
http://192.168.194.101:8080/login?from=%2F
# 查看密码
cat /var/lib/jenkins/secrets/initialAdminPassword
2) 卸载步骤
rpm -e jenkins #rpm卸载
rpm -ql jenkins #检查是否卸载成功
find / -iname jenkins | xargs -n 1000 rm -rf #彻底删除残留文件
Linux安装系列:构建Jenkins自动化部署
于 2022-11-26 11:04:49 首次发布