Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the docker command to run jenkins container in windows

What is the correct docker run ... command to run jenkins container.

  1. What are the required ports?
  2. How to mount volume D:\jenkins folder to jenkins job configuration path?

I'm using linux containers on windows 10.

like image 542
sith Avatar asked Oct 20 '16 03:10

sith


People also ask

How do I run a Docker container in CMD?

To use the docker exec command, you will need a running Docker container. If you don't already have a container, start a test container with the following docker run command: docker run -d --name container-name alpine watch "date >> /var/log/date. log"


1 Answers

docker run -p 8080:8080 -p 50000:50000 -v //D/jenkins:/var/jenkins_home jenkins

or with : -v D:/jenkins:/var/jenkins_home like in example below but i personally prefer first approach.

just make sure in docker settings you have checked disc D to allow mounting D

Share Drives settings example

like image 104
VladoDemcak Avatar answered Oct 20 '22 00:10

VladoDemcak