docker 安装 Jenkins ,linux宿主机(centos7)安装jenkins

安装
docker pull jenkinsci/blueocean

docker run \
  -d \
  -u root \
  -p 8050:8080 \
  -p 50000:50000 \
  -v /mydata/jenkins:/var/jenkins_home \
  -v /var/run/docker.sock:/var/run/docker.sock \
  -v /usr/bin:/usr/bin \
 --name jenkins yansl/jenkins

宿主机安装
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.key

yum install -y jenkins 默认安装最新的

启动jenkins
service jenkins start

相关目录:
/usr/lib/jenkins/jenkins.war WAR包

/etc/sysconfig/jenkins 配置文件

/var/lib/jenkins/ 默认的JENKINS_HOME目录

/var/log/jenkins/jenkins.log Jenkins日志文件

你可能感兴趣的:(docker 安装 Jenkins ,linux宿主机(centos7)安装jenkins)