搭建jenkins服务器
1. jenkins介绍
jenkins官网:https://jenkins.io/zh/
项目源码:https://github.com/jenkinsci/jenkins
2. docker安装jenkins
1 )下载jenkins的docker镜像
docker pull jenkins
2 )创建jenkins存储目录
mkdir /home/var/jenkins
3 )cd进入/home/var/目录,设置jenkins文件夹的归属用户UID为1000
chown -R 1000:1000 jenkins/
4 )使用jenkins镜像创建容器
docker run -itd -p 8080:8080 -p 50000:50000 --name jenkins --privileged=true -v /home/var/jenkins:/var/jenkins_home jenkins