playground/docker-jenkins
2021-09-02 10:50:47 +00:00
..
build-initial-centos6.sh updating build-initial-centos6.sh 2021-09-02 10:50:47 +00:00
build-initial.sh added some dockers for building jenkins agents 2021-08-24 14:04:31 +00:00
centos6-eol.repo centos6 docker image builder for jenkins 2021-08-24 15:57:01 +00:00
Dockerfile added some dockers for building jenkins agents 2021-08-24 14:04:31 +00:00
Dockerfile.centos6 centos6 docker image builder for jenkins 2021-08-24 15:57:01 +00:00
Makefile added some dockers for building jenkins agents 2021-08-24 14:04:31 +00:00
readme.txt updated some jenkins information 2021-08-25 15:12:35 +00:00

pull the jenkins lts image.
# docker pull jenkins/jenkins:lts

start a jenkins container.
# mkdir -p ${HOME}/data/jenkins_1_home
# docker run -p 8081:8080 --name jenkins-1 --restart=unless-stopped -d -i -t -v ${HOME}/data/jenkins_1_home:/var/jenkins_home jenkins/jenkins:lts


instead of mapping to a specific directory, make may to a named volume.
# docker run -p 8081:8080 --name jenkins-1 -v jenkins_1_home:/var/jenkins_home jenkins/jenkins:lts
# docker volume create jenkins_1_home
# docker volume ls
# docker volume inspect jenkins_1_home


## on some other build machines, you may create agent images and run them
make centos6-jenkins
docker run -d -p 9922:22  --name=debian-jenkins-agent --restart=unless-stopped debian-jenkins:latest /usr/sbin/sshd -D

make debian-jenkins
docker run -d -p 9923:22  --name=centos6-jenkins-agent --restart=unless-stopped centos6-jenkins:latest /usr/sbin/sshd -D