Explain the Docker architecture: daemon, client, Desktop, and registries.
Take a moment.
Say your answer out loud or write it down first — retrieval is what makes it stick. Reveal when you're ready.
Short answer
Docker is client-server: the docker CLI sends REST API calls (over a socket or network) to dockerd, which builds, runs, and distributes containers. Docker Desktop bundles daemon + client + Compose + Kubernetes for Mac/Windows/Linux; registries like Docker Hub store and distribute images via pull/push.
Detailed explanation
The Docker daemon (dockerd) does the heavy lifting — it listens for API requests and manages images, containers, networks, and volumes, and can coordinate with other daemons for services. The Docker client (docker) is the primary interface: docker run does not run anything itself, it sends a command to dockerd, which carries it out. Client and daemon may live on the same machine or the client may drive a remote daemon, and one client can talk to many daemons. Docker Compose is a second client for multi-container apps. Docker Desktop is the easy-install bundle containing dockerd, the client, Compose, Content Trust, Kubernetes, and Credential Helper. Registries close the loop: docker pull fetches required images from the configured registry (Docker Hub by default), docker push publishes yours — you can also run a private registry or use ECR/ACR/GCR.
Official docs:Docker docs: Docker overview
Example
# Client → daemon over the Docker API:
docker run -d -p 8080:80 nginx # CLI sends request
dockerd # pulls image, creates container +
# network + filesystem, starts process
docker pull nginx # download from registry (Docker Hub by default)
docker push my-user/my-app:1.0 # publish to registryInterview tip
Stress that the CLI is a thin REST client — docker run is an API call, not local execution. Then place Desktop (bundle) and Hub (default registry) in one sentence each.
Common mistakes
- Saying the docker CLI builds or runs containers itself.
- Not knowing Hub is just the default registry and pull/push target it.