Guide Docker Beginner

3. Docker Architecture

Trace a Docker command through the client, daemon, registry, and runtime.

1 min read

Main Components

ComponentResponsibility
Docker CLISends commands to the selected Docker endpoint
Docker daemonManages images, containers, networks, and volumes
RegistryStores and distributes images
Container runtimeCreates and runs container processes

The daemon can run on a different machine from the CLI. Bind-mount paths refer to the daemon host, which matters when using a remote context.

What Happens During docker run?

flowchart LR CLI[Docker CLI] --> Daemon[Docker daemon] Registry[Image registry] --> Daemon Daemon --> Container[Container process] Container --> Network[Container network] Container --> Storage[Mounted storage]

The daemon resolves the image locally or pulls it when needed, prepares the container filesystem and configuration, and starts the configured process.

Inspect the Environment

docker context show
docker info
docker image ls
docker container ls -a

Images and containers are separate resources. An image can exist without a running container, and many containers can use the same image.

Practice

Find one image and list containers created from it. Identify which commands inspect stored artifacts and which inspect runtime instances.

Quick Interview Answer

Docker uses a client-server architecture. The client talks to the daemon, which manages local resources and uses registries to obtain or publish images.


Previous: 2. Installation and Verification | Next: 4. Container Lifecycle

Add More Questions to This Guide

Know a question that should be here? Share it and help the community!

Open Google Form