Challenge - 5 Problems
Docker Inspect Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
💻 Command Output
intermediate2:00remaining
Inspecting container network settings
You run the command
docker inspect my_container and want to find the IP address assigned to the container. Which command filters the IP address correctly?Attempts:
2 left
💡 Hint
Look inside the NetworkSettings section for IP details.
✗ Incorrect
The IP address of a Docker container is stored under NetworkSettings.IPAddress. The other options point to incorrect or non-existent fields.
💻 Command Output
intermediate2:00remaining
Finding container mount points
Which
docker inspect command shows the source paths of volumes mounted inside a container named webapp?Attempts:
2 left
💡 Hint
Mount points are listed under the Mounts array.
✗ Incorrect
The Mounts array contains details about volume mounts including their source paths. The other fields do not provide this information directly.
❓ Troubleshoot
advanced2:00remaining
Diagnosing missing environment variables
You inspect a container but notice the environment variables you set are missing. Which field in the
docker inspect output should you check to verify environment variables?Attempts:
2 left
💡 Hint
Environment variables are part of the container configuration.
✗ Incorrect
Environment variables are stored in the Config.Env field. Other fields do not contain environment variable information.
🧠 Conceptual
advanced2:00remaining
Understanding Docker inspect output format
What is the default output format of the
docker inspect command?Attempts:
2 left
💡 Hint
Think about the data format used for structured output in Docker CLI.
✗ Incorrect
The default output of docker inspect is JSON, which provides detailed structured information about containers or images.
✅ Best Practice
expert2:00remaining
Efficiently extracting container creation time
You want to get only the creation time of a container named
dbserver using docker inspect. Which command is the most efficient and correct?Attempts:
2 left
💡 Hint
Creation time is a top-level field in the inspect JSON.
✗ Incorrect
The Created field is at the top level of the inspect output. Using the Go template with -f flag to extract {{ .Created }} is efficient and precise.