About Docker… #
Docker is a set of tools used to manage and run containers.
When you use docker, you interact mostly with Docker CLI.
The cli talks to docker daemon (dockerd) using a REST api.
Dockerd uses containerd to actually run containers.
Docker adopted the Open Container Initiative (OCI) standards.
Docker images are now OCI-compliant images, and Docker’s runtime components (like containerd and runC) are OCI-compliant runtimes.
What are containers #
Containers are isolated, lightweight, and portable units that package an application and its dependencies.
Unlike virtual machines, containers do not include an entire guest operating system; they share the host’s OS kernel. This shared kernel is what makes them significantly lighter and faster to start than VMs.
Containers use Linux kernel features - namespaces and cgroups (control groups).
Resources #
Snippets #
View healthcheck logs:
docker inspect --format "{{json .State.Health }}" $CONTAINER | jq