On windows 7 I am using Docker tool box and not able to ping jenkins running in container

Hello,

I have installed DockerToolbox.exe and running jenkins latest version. When ever I am pinging Jenkins from my browser, it is not connecting to jenkins server. I am also sure that jenkins is running on 8080 port of Docker.

I am using Windows 7.

The below is the url which I am following for complete docker and jenkins set up.

Pls provide your Dockerfile and/or docker-compose. Also give us some information about the systems you are running on (Linux native Docker? Docker for Mac? Windows native or Windows Toolbox?).

The way you asked your question is basically as if you were asking a mechanic “I left my car at home, but it doesn’t work. Can you tell me what’s wrong?”. The answer is obviously: “No, cause I don’t have any information about the car.”

Hello Sir/Madam,

I am Using “Docker Toolbox for Windows”.

I am using Windows 7.

The below is the url which I am following for complete docker and jenkins set up.

https://github.com/schoolofdevops/learn-jenkins

Hello worp,

I am using Windows Toolbox.
docker commands were:
1> $docker run -idt --name jenkins -v /var/run/docker.sock:/var/run/docker.sock -p 8080:8080 -p 50000:50000 schoolofdevops/jenkins
2> $docker start jenkins

Then hitting the ip:8080 on browser. Then not getting connection

Are you trying to go to localhost:8080 in your browser?

Since you’re running on Toolbox you’ll need to use the Docker Toolbox’s IP. Try running:

$ docker-machine ls
NAME            ACTIVE   DRIVER       STATE     URL                         SWARM   DOCKER        
ERRORS
default          -        virtualbox   Running   tcp://192.168.99.101:2376           v18.04.0-ce

Then go to http://192.168.99.101:8080 in your browser.
(Use whatever IP that “docker-machine ls” spills out on your computer)

Thanks Worp.

Now I am able to run jenkins on Docker.

Glad I was able to help! Enjoy Docker!

Kindly note: Jenkins docker port should always be 8080, the host port can be any other port