一、CentOS8:Docker搭建Jenkins2.60.3版本

1. 配置jenkins启动命令

启动镜像文件前提:在宿主机配置好jenkins容器挂载地址,防止数据丢失

# 新建jenkins_home2.60.3文件夹
$ mkdir /home/wyt/jenkins_home2.60.3# 设置权限
$ sudo chown -R 1000:1000 /home/wyt/jenkins_home2.60.3

jenkins2.60.3.sh脚本

#! /bin/bash
docker rm -f myjkdocker run --name myjk \
-d -p 8080:8080 \
-p 50000:50000 \
-v /home/wyt/jenkins_home2.60.3:/var/jenkins_home \
--env JAVA_OPTS="-Dhudson.model.DownloadService.noSignatureCheck=true" jenkins# -v /usr/local/apache-maven-3.6.3:/usr/local/apache-maven-3.6.3 \
# -v /usr/local/allure-2.17.2:/usr/local/allure-2.17.2 \

jenkins.sh赋予可执行权限,并启动

$ chmod +x jenkins2.60.3.sh
$ ./jenkins2.60.3.sh

查看密码,并记录下来,下次启动jenkins时使用

$ docker exec -it myjk bashdf825cff514d42798eac55d42ede1f78


打开http://localhost:8080

到下面这步,点【x】

注意:这里是说用户名是admin,密码在/home/wyt/jenkins_home2.60.3/secrets/initialAdminPassword

2. 配置jenkins插件管理

查看对应的版本
https://gitee.com/jenkins-zh/cloudbees-folder-plugin

https://updates.jenkins-ci.org/download/plugins/cloudbees-folder/
下载cloudbees-folder.hpi,注意:版本6.2.1-6.5.1支持jenkins2.60.3

阿里云镜像站 https://mirrors.aliyun.com/jenkins/updates/2.60/
复制update-center.json地址,注意:版本号2.60

上传插件:cloudbees-folder.hpi


更换成阿里的升级站点(注意:一定要点击【提交】
https://mirrors.aliyun.com/jenkins/updates/2.60/update-center.json

重启jenkins

$ ./jenkins2.60.3.sh

将刚才的密码写入

进入插件管理,点击【立即获取】

3. 更换jenkins下载源

安装Gitee插件报错

java.io.IOException: Downloaded file /var/jenkins_home/plugins/gitee.jpi.tmp does not match expected SHA-1, expected 'NF8iQWp+h9lro5S4yo+3XGWHJgg=', actual 'w85og1XeUx+Lrwewtk7rDR98BsE='at hudson.model.UpdateCenter.verifyChecksums(UpdateCenter.java:1810)at hudson.model.UpdateCenter.access$1100(UpdateCenter.java:149)at hudson.model.UpdateCenter$InstallationJob.replace(UpdateCenter.java:1963)at hudson.model.UpdateCenter$UpdateCenterConfiguration.install(UpdateCenter.java:1194)at hudson.model.UpdateCenter$DownloadJob._run(UpdateCenter.java:1680)at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1874)at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1651)at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)at java.util.concurrent.FutureTask.run(FutureTask.java:266)at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110)at java.lang.Thread.run(Thread.java:748)

解决办法:

注意:第1步可以不用做,前面升级站点就是修改的这里
1、修改 jenkins 数据目录中的hudson.model.UpdateCenter.xml值,将https://updates.jenkins.io/update-center.json/更换为阿里云https://mirrors.aliyun.com/jenkins/updates/2.60/update-center.json
sed -i  's/https:\/\/updates.jenkins.io\/update-center.json/https:\/\/mirrors.aliyun.com\/jenkins\/updates\/2.60\/update-center.json/g' /home/wyt/jenkins_home2.60.3/hudson.model.UpdateCenter.xml2、修改updates文件夹中的 default.json文件,将http://updates.jenkins-ci.org/download/更换为阿里云https://mirrors.aliyun.com/jenkins/
sed -i  's/http:\/\/updates.jenkins-ci.org\/download/https:\/\/mirrors.aliyun.com\/jenkins/g' /home/wyt/jenkins_home2.60.3/updates/default.json
sed -i  's/http:\/\/www.google.com/http:\/\/www.baidu.com/g' /home/wyt/jenkins_home2.60.3/updates/default.json3、在浏览器中http:localhost:8080/restart,重启一下Jenkins

  • 可以下载自己想要的插件了

遇到问题1


解决办法:
https://blog.csdn.net/DDJ_TEST/article/details/122210331

遇到问题2

java.io.IOException: Downloaded file /var/jenkins_home/plugins/gitee.jpi.tmp does not match expected SHA-1, expected 'NF8iQWp+h9lro5S4yo+3XGWHJgg=', actual 'w85og1XeUx+Lrwewtk7rDR98BsE='at hudson.model.UpdateCenter.verifyChecksums(UpdateCenter.java:1810)at hudson.model.UpdateCenter.access$1100(UpdateCenter.java:149)at hudson.model.UpdateCenter$InstallationJob.replace(UpdateCenter.java:1963)at hudson.model.UpdateCenter$UpdateCenterConfiguration.install(UpdateCenter.java:1194)at hudson.model.UpdateCenter$DownloadJob._run(UpdateCenter.java:1680)at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1874)at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1651)at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)at java.util.concurrent.FutureTask.run(FutureTask.java:266)at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110)at java.lang.Thread.run(Thread.java:748)

解决办法:

注意:第1步可以不用做,前面升级站点就是修改的这里
1、修改 jenkins 数据目录中的hudson.model.UpdateCenter.xml值,将https://updates.jenkins.io/update-center.json/更换为阿里云https://mirrors.aliyun.com/jenkins/updates/2.60/update-center.json
sed -i  's/https:\/\/updates.jenkins.io\/update-center.json/https:\/\/mirrors.aliyun.com\/jenkins\/updates\/2.60\/update-center.json/g' /home/wyt/jenkins_home2.60.3/hudson.model.UpdateCenter.xml2、修改updates文件夹中的 default.json文件,将http://updates.jenkins-ci.org/download/更换为阿里云https://mirrors.aliyun.com/jenkins/
sed -i  's/http:\/\/updates.jenkins-ci.org\/download/https:\/\/mirrors.aliyun.com\/jenkins/g' /home/wyt/jenkins_home2.60.3/updates/default.json
sed -i  's/http:\/\/www.google.com/http:\/\/www.baidu.com/g' /home/wyt/jenkins_home2.60.3/updates/default.json3、在浏览器中http:localhost:8080/restart,重启一下Jenkins

CentOS8:Docker搭建Jenkins2.60.3版本,及更换jenkins下载源相关推荐

  1. K8S搭建自动化部署环境(三)Jenkins下载、安装和启动

    各位大佬,前文如下: K8S搭建自动化部署环境(一)安装Kubernetes K8S搭建自动化部署环境(二)安装K8S管理工具Kuboard V3 一.jenkins 下载 jenkins下载地址:h ...

  2. 使用Docker搭建Nextcloud个人工作中心(同步盘+离线下载等功能)以及DNS服务器搭建

    目录 前言 需求 选型 环境说明与准备工作 环境 软件准备 Nextcloud本地搭建(Nextcloud+Redis+Mysql) Nextcloud公网访问(可选) 使用同一域名解析至公网或内网I ...

  3. K8S搭建自动化部署环境(四)Jenkins多分支流水线Blue Ocean的安装和使用

    各位大佬,前文如下: K8S搭建自动化部署环境(一)安装Kubernetes K8S搭建自动化部署环境(二)安装K8S管理工具Kuboard V3 K8S搭建自动化部署环境(三)Jenkins下载.安 ...

  4. 使用Docker搭建ceph群集(nautilus版本)

    使用Docker搭建ceph群集(nautilus版本) 一.ceph简介 概述 Ceph是一种为优秀的性能.可靠性和可扩展性而设计的统一的.分布式文件系统.Ceph是一个开源的分布式文件系统.因为它 ...

  5. 使用docker搭建gitlab版本控制系统

    1. GitLab 简介 GitLab 是一款基于 git 的开源代码仓库系统  GitLab 与著名的 GitHub 最大的区别就是:  允许我们搭建自己的 git 代码私有仓库,非常方便 2.安装 ...

  6. docker image设置jdk版本_使用Docker搭建Java环境的步骤方法

    Docker是干什么的 Docker 是一个基于Linux容器(LXC-linux container)的高级容器引擎,基于go语言开发,源代码托管在 Github 上, 遵从Apache2.0协议开 ...

  7. 群晖docker_利用群晖docker搭建Minecraft服务器:图形界面操作,傻瓜式教程(附官方服务器端地址)_NAS存储...

    2020-12-19 18:01:5310点赞57收藏4评论 你是AMD Yes党?还是intel和NVIDIA的忠实簇拥呢?最新一届#装机大师赛#开始啦!本次装机阵营赛分为3A红组.intel NV ...

  8. docker搭建mysql主从

    前言 为什么要使用Docker搭建? 不管是使用源码安装还是离线安装,在服务器上安装一个mysql总会花费不少的时间,而且对于新人来说,中间稍不注意哪一步出错了就导致安装失败,我之前也是安装过2次才成 ...

  9. VPS服务-Docker搭建个人博客网站

    容器安装 本人购买的 VPS 服务器是 Centos 8 操作系统,为了基于 Docker 搭建 WordPress 个人博客网站,首先需要安装 Docker 环境的过程如下: 1.下载 docker ...

最新文章

  1. 对抗攻击最新研究:仅修改「一个像素」即可骗过神经网络!
  2. 设计模式重构代码_Duplicated Code (重复代码)如何处理?
  3. centos利用tar包安装phpmyadmin
  4. CF1473E Minimum Path(拆点+最短路)
  5. JAVA_Thread_deadlock
  6. 固件的完整形式是什么?
  7. 横跨7个版本的OpenStack无感知热升级在360的落地与实践
  8. Apple individual program 加入之后的玩法 官方资源
  9. 32、至少列举8个常用模块都有那些?
  10. DSP 6678 多核CACHE一致性操作
  11. adventureworks mysql_AdventureWorks2012
  12. UE 编辑器无法保存文件(图表被连接到外部包中的私有对象)
  13. 关于unity,Player打包面板的信息(上)
  14. 毫米波雷达测距/测速原理介绍_小七自学笔记
  15. 2022年山东省安全员C证考试资料及山东省安全员C证考试试题
  16. linux C之srand函数
  17. 相亲聊什么?想要避免尬聊,就从这6个话题入手
  18. 五分钟学会前端打包工具webpack
  19. 1024程序员节获奖名单放榜啦,云端技术奥秘大使就是你!
  20. few-shot learning个人总结

热门文章

  1. 逆向一个IOS CrackMe
  2. 培训笔记之WIZnet的主要产品是什么?
  3. 区块链难在落地,亟需补人才缺口迎爬升期
  4. 法学硕士可以调剂计算机专业吗,法学研究生可以调剂为法律硕士吗?
  5. 数据化管理洞悉零售及电子商务——数据分析方法
  6. 计算机软件小白的学习历程
  7. 2023届双非计算机硕士算法岗秋招总结
  8. MATLAB:牛顿环干涉实验(Newton’s Ring)
  9. win7 没有信息服务器地址,win7电脑提示无法解析服务器dns地址,该如何解决?
  10. 元宇宙体育俱乐部 #kodeclubs 基于threejs的网页版虚拟空间