自动化部署-01-jenkins安装


前言

spingcloud微服务等每次部署到服务器上,都需要本地编译打包,然后将打好的包上传到服务器再启动。这样比较麻烦。我们可以使用自动化部署,自动在服务器上部署新代码。
jenkins部署版本是:2.462.3
我是使用的部署skywalking的虚拟机10.211.55.120,已经装好了open-jdk-21.0.2,但这个jdk版本安装jenkins有点问题。


一、下载安装

参考文档:
https://www.jenkins.io/doc/book/installing/linux/
https://pkg.jenkins.io/redhat-stable/

我的虚拟机是CentOS系统,所以执行:

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-2023.key
#安装
yum install jenkins

以下是详情

[root@localhost config]# sudo wget -O /etc/yum.repos.d/jenkins.repo https://pkg.jenkins.io/redhat-stable/jenkins.repo
--2024-10-24 16:58:31--  https://pkg.jenkins.io/redhat-stable/jenkins.repo
Resolving pkg.jenkins.io (pkg.jenkins.io)... 151.101.194.133, 151.101.66.133, 151.101.130.133, ...
Connecting to pkg.jenkins.io (pkg.jenkins.io)|151.101.194.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 85
Saving to: ‘/etc/yum.repos.d/jenkins.repo’

/etc/yum.repos.d/jenkins.repo                 100%[==============================================================================================>]      85  --.-KB/s    in 0s      

2024-10-24 16:58:33 (200 KB/s) - ‘/etc/yum.repos.d/jenkins.repo’ saved [85/85]

[root@localhost config]# sudo rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io-2023.key
[root@localhost config]# yum install jenkins
Jenkins-stable                                                                                                                                       8.0 kB/s |  29 kB     00:
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

搬砖天才、

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值