(Docker Training Course for the Absolute Beginner)
I’d like to suggest a re-recording or update for the lecture “Demo - Advanced Docker Run Features”, as the current version may cause confusion for absolute beginners due to the following reasons:
1. Explanation of docker ps
Output — Incomplete
In the current video, the PORTS
column is not adequately explained. For example, in the attached screenshot, the docker ps
output shows:
PORTS
8080/tcp, 50000/tcp
What this means:
-
8080/tcp: This is Jenkins’ internal web UI port.
-
50000/tcp: Used by Jenkins agents (JNLP).
- However, there’s no
->
symbol, which means these ports are not mapped to the host (i.e., they are not accessible externally).
Why the Jenkins UI is inaccessible at http://localhost:8080
:
Because the container was started with just:
docker run jenkins/jenkins
No ports were published, so the host cannot access the container’s internal ports.
Proper command to expose ports to host:
docker run --name myjenkins -p 8080:8080 -p 50000:50000 -d jenkins/jenkins
This results in:
PORTS
0.0.0.0:8080->8080/tcp, 0.0.0.0:50000->50000/tcp
allowing access via browser at http://localhost:8080
.
2. Docker Desktop Note – No VM IP Available
The lecture mentions accessing Jenkins via an internal VM, using container IP. However, on Docker Desktop, no separate VM is created or exposed this way — students should instead access via localhost
, post exposing the ports.
3. Clarify: Use localhost
, Not IP Address
Please recommend using:
http://localhost:8080
instead of fetching or guessing the host’s IP address.
-
Fetching Jenkins Setup Password
Include the command to retrieve the Jenkins setup password:
docker exec <container_name> cat /var/jenkins_home/secrets/initialAdminPassword
These clarifications can significantly reduce confusion for learners who are new to Docker and Jenkins. Thank you for the great content so far!
Best regards,
Aditya Garg