
Docker uses a client-server architecture: the Docker client sends commands to the Docker daemon, which builds images, runs containers and pulls or pushes images from a registry. A container is an isolated process created from a read-only image, so the same application runs the same way on a laptop, a test server or the cloud.
This guide walks through each component of Docker's architecture, how a typical workflow uses them, how Docker compares with virtual machines, and where Docker's limits are.
| Component | What it does |
|---|---|
| Docker client (CLI) | Where you type commands such as docker build and docker run; sends them to the daemon through the Docker API |
| Docker daemon (dockerd) | Background service that builds images and manages containers, networks and volumes |
| containerd and runc | Lower-level runtimes the daemon uses to actually start and stop containers |
| Image | Read-only, layered template containing the app, its dependencies and settings |
| Container | A running instance of an image, with its own writable layer, network and process space |
| Registry | Stores and shares images; Docker Hub is the default public registry |
| Networks | Connect containers to each other and to the outside world |
| Volumes | Keep data outside the container so it survives restarts and upgrades |
The client is the main way users interact with Docker. It can talk to a daemon on the same machine or on a remote host. Docker Desktop bundles the client, daemon and a graphical interface for Windows and macOS.
The daemon listens for API requests and does the work: building images, creating and stopping containers, and managing networks and storage. It delegates the low-level container lifecycle to containerd, which uses runc to create the isolated process.
An image is built from a Dockerfile, a plain-text file of instructions such as FROM, COPY, RUN and CMD. Each instruction creates a read-only layer. Layers are cached and shared between images, which makes builds and downloads faster. Images follow the OCI (Open Container Initiative) format, so other container tools can run them too.
Starting an image creates a container: the image layers plus a thin writable layer on top. Containers are isolated using Linux kernel features (namespaces for isolation, cgroups for resource limits). Anything written inside the container's writable layer is lost when the container is removed, which is why persistent data belongs in volumes.
A registry stores versioned images. Docker Hub is public by default; most companies also use a private registry such as Amazon ECR, Azure Container Registry, Google Artifact Registry or GitLab's registry. docker push uploads an image and docker pull downloads it.
Volumes are managed storage outside the container's filesystem. Databases, uploads and logs should live in volumes so they survive when containers are replaced.
Docker Compose defines multi-container applications in a YAML file (for example, a web app, a database and a cache) and starts them with one command. Docker Swarm is Docker's built-in clustering for running containers across several machines; many teams use Kubernetes instead for large-scale orchestration.
docker build sends the build context to the daemon, which creates the image layer by layer.docker push uploads the image to a registry with a version tag.docker pull and docker run, and the daemon starts a container from that exact image.| Docker container | Virtual machine | |
|---|---|---|
| What it virtualises | The operating system (shares the host kernel) | The hardware (each VM runs its own OS) |
| Size | Usually megabytes | Usually gigabytes |
| Start time | Seconds or less | Minutes |
| Isolation | Process-level; strong enough for most apps | Stronger; separate kernels |
| Best for | Microservices, CI/CD, consistent dev environments | Running different operating systems, strict isolation needs |
The Docker client, the Docker daemon, images, containers and registries. Networks and volumes support them, and Docker Compose and Swarm add multi-container and multi-host management.
No. An image is the read-only template; a container is a running instance of it. One image can run as many containers.
Not entirely. Containers are lighter and faster for most applications, but VMs still suit workloads that need a different OS or stronger isolation. Many teams run containers inside VMs.
Docker Engine is open source. Docker Desktop is free for personal use, education and small businesses, with paid plans for larger companies.
Ellocent Labs containerises applications and builds deployment pipelines as part of our DevOps services. Book a discovery call to plan a migration.
We've built both. We'll tell you honestly which one fits.
From no-code MVPs validated in 6 weeks to enterprise AI platforms with 50,000+ users, we've built across the whole range. Book a consultation and we'll tell you honestly which approach fits your budget, your timeline, and your scale ambitions.