Home Cloud Docker architecture

Docker architecture

559
0

In previous article we learned “What is Docker?”.

Now we will discuss about it’s architecture.

Docker uses a client-server architecture model in which the client talks to the Docker daemon (the background process), which does the job of building, running, and distributing your containers. The Docker client and daemon can run on the same system, or you can connect a Docker client to a remote Docker daemon. The Docker client and daemon communicate using a REST API, over UNIX sockets, or a network interface.

source: https://docs.docker.com/get-started/overview

The Docker daemon (dockerd)

The Docker daemon manages Docker objects such as images, containers, networks, and volumes. A daemon can also communicate with other daemons to manage Docker services.

The Docker client

The Docker client is used to interact with Docker. When you use commands such as docker run, the client sends these commands to dockerd, which carries them out. The docker command uses the Docker API. The Docker client can communicate with more than one daemon.

Docker registries

A Docker registry stores Docker images. Docker Hub is a public registry that anyone can use, and Docker is configured to look for images on Docker Hub by default.

When you use the docker pull or docker run commands, the required images are first looked in to your system; if they are not present then they are pulled from your configured registry. When you use the docker push command, your image is pushed to your configured registry.

Docker objects

When you use Docker, you are creating and using images, containers, networks, volumes, plugins, and other objects. This section is a brief overview of some of those objects.

Images

An image is a read-only template with instructions for creating a Docker container. An image can be based on another image, with some additional customization. For example, you may build an image which is based on the ubuntu image, but installs the Apache web server and your application. You might create your own images or you might only use those created by others or published in a registry.

Containers

A container is a runnable instance of an image. You can create, start, stop, move, or delete a container using the Docker API or CLI. When a container is removed, any changes to its state that are not stored in persistent storage disappear.

Stay tuned for more articles.

This site uses Akismet to reduce spam. Learn how your comment data is processed.