How to run Jenkins on Docker container | How to create Jenkins Volumes on Docker | Beginners

Описание к видео How to run Jenkins on Docker container | How to create Jenkins Volumes on Docker | Beginners

more about Raghav - https://automationstepbystep.com/
Jenkins Playlist - http://bit.ly/2FjPMpo

For those who are having a permission issue like this:
Use the --privileged tag with the docker run command
OR
touch: cannot touch '/var/jenkins_home/copy_reference_file.log': Permission denied
Can not write to /var/jenkins_home/copy_reference_file.log. Wrong volume permissions?

change your destination folder's owner and group to uid 1000, like this
sudo chown 1000:1000 /path/to/your/folder

This is probably not the best solution and you shouldn't really just do it in production just from this comment. This is just to get you to follow along this tutorial. Please google and research more about this issue before going into production.

Today we will learn :
1. How to start Jenkins on Docker Container
2. Start and Stop Jenkins Container
3. How to set Jenkins home on Docker Volume and Host Machine
: docker pull jenkins
: docker run -p 8080:8080 -p 50000:50000 jenkins
: docker run --name MyJenkins -p 8080:8080 -p 50000:50000 -v /Users/raghav/Desktop/Jenkins_Home:/var/jenkins_home jenkins
: docker run --name MyJenkins2 -p 9090:8080 -p 50000:50000 -v /Users/raghav/Desktop/Jenkins_Home:/var/jenkins_home jenkins
: docker volume create myjenkins
: docker volume ls
: docker volume inspect myjenkins
: docker run --name MyJenkins3 -p 9090:8080 -p 50000:50000 -v myjenkins:/var/jenkins_home jenkins
: docker inspect MyJenkins3
In case you face issues like installing plugins on this Jenkins, can setup jenkins with this command:
$ docker run -u root --rm -p 8080:8080 -v /srv/jenkins-data:/var/jenkins_home -v /var/run/docker.sock:/var/run/docker.sock --name jenkins jenkinsci/blueocean

References
https://hub.docker.com/

A useful information by shared by Nilanjan Dutta:
Installed docker client binaries in the jenkins image, added the jenkins user to the docker group and provided full permission to the docker.socket process..in case anyone finds this useful.
_____________________________________________________________

#DockerJenkins #JenkinsOnDocker #DockerTutorials #DockerTraining #DevOpsTools #DevOpsTraining #DockerCommands #DockerForBeginners #DockerFreeTutorials #DockerforDevOps

DOCKER PLAYLIST
   • Docker  

YOUTUBE PLAYLIST
   / @raghavpal  

YOUTUBE
   / automationstepbystep  

FACEBOOK
  / automationstepbystep  

TWITTER
  / automationsbs  

If you like videos on the channel Automation Step by Step, hit the like button and share with others.

Click the SUBSCRIBE button and hit the bell icon to keep getting new videos.


_______ ONLINE COURSES TO LEARN _______

Visit - https://automationstepbystep.com/

----------- Follow -----------
Youtube -    / automationstepbystep  

Share your knowledge with everyone and,
Never Stop Learning
Raghav

Комментарии

Информация по комментариям в разработке