What are Docker images and Docker containers?
Accenture technical mcq question, verified with a worked answer. Free to practise - no sign-up.
What are Docker images and Docker containers? Choose the correct option.
Show answer & explanation
Option B correctly defines the relationship: Docker images are archive files (blueprints/templates) that contain the OS, libraries, code, and dependencies, while Docker containers are the running instances created from those images. Options A and D reverse this relationship incorrectly. Option C incorrectly describes containers as files, when they are actually runtime instances.
Step-by-step Derivation:
Docker fundamentals: A Docker image is a lightweight, standalone, executable package stored as an archive containing application code, runtime, system tools, and dependencies. A Docker container is an instantiated, running process created from a Docker image. The image is static (a template), and the container is dynamic (a running instance). Only Option B accurately captures this image-as-blueprint and container-as-instance distinction.