Moving Forward with Docker Architecture: 
Exploring the Core Components

Moving Forward with Docker Architecture: Exploring the Core Components

Docker Architecture Docker architecture is made up of a few key components that work together to make containerization easy and efficient such as Docker Engine, Docker Client, Docker Daemon etc.

Docker Client

This is the interface where users interact with Docker. A client is a user who can interact with client terminal by using commands like ‘docker run’ or ‘docker build’ to tell Docker what to do. Further, these commands are processed to Docker Daemon.

Docker Host

It contains all the components used to provide an environment to execute and run applications such as Docker Daemon, images, containers, networks and storage.

Docker Daemon

The daemon is the background service that listens for commands from the Docker client. It runs over host machine and responsible for managing Docker containers, images, and other resources on your machine.

Docker Images

Images are like blueprints or read-only binary templates for containers. Docker images are immutable and reusable. They contain everything needed to run an application, including code, libraries, and settings. Images can be created by a Dockerfile or directly pull from Docker Hub or Registry.

Docker Containers

Containers are the running instances of Docker images. Containers hold the entire package to run applications consistently on any machine. They are lightweight and run over the Docker Engine.

Containerd

It manages the container lifecycle, including starting, stopping, pausing, and deleting containers.

Docker Registry

This is where Docker images are managed and stored. There are two types of registries: Public Registry and Private Registry. The most popular public registry is Docker Hub. Private registries are used to share images with in the enterprise.

Docker Network

This allows containers to talk to each other and the outside world. It helps containers share data and work together. Few types of docker networks are Bridge network, Host network, Overlay network, User-Defined Networks and None.

Docker Volumes

Volumes are used to store data outside of containers. It is important to persist data even if containers are stopped or deleted.

Let’s see how these components interact and provide a concise flow when a client runs, builds, or pulls an image. Docker Image can be built by using already-existing image directly or by using a Dockerfile.

Case1- Running Docker image

A Client issues the ‘docker run ’ command on terminal which further interact with Docker Daemon.

Now: Daemon checks if the image is available locally:

o If yes, it creates and starts a container from the image.

o If no, it pulls the image from the registry.

o Pulled image is stored locally for future use.

As a result: Container runs the application inside an isolated environment.

Case2- Building a Docker Image

A Client issues the docker build -t command with a Dockerfile.

Now: Daemon reads the Dockerfile, executes instructions and builds the image.

The image is created and stored locally.

In both cases, the Docker client interacts with the Docker daemon, which manages the images, containers, and interactions with the registry.