Docker is a tool designed that makes easier to create, deploy, and run applications by using containers. Therefore, containers allow developers to package up application with all of the dependencies, and ship it all out as one package.
Kubernetes, or k8s, is an open source platform that automates Linux container operations. In other words, you can cluster together groups of hosts running containers, and Kubernetes helps you easily and efficiently manage those clusters.
In order to run the containres kubernetes uses a container runtime, that is a software component that executes containers and manages container images on a node. Today, the most widely known container runtime is Docker, but there are other container runtimes in the ecosystem, such as rkt, containerd, and lxd.
So to use docker as a container runtime kubernetes uses shim or a piece of software that resides in between a container manager (containerd, cri-o, podman) and a container runtime (runc, crun) solving the integration problem of these counterparts.
Nevertheless, maintaining dockershim has become a heavy burden on the Kubernetes maintainers. The CRI standard was created to reduce this burden and allow smooth interoperability of different container runtimes. Docker itself doesn’t currently implement CRI, thus the problem.
Dockershim was always intended to be a temporary solution (hence the name: shim). You can read more about the community discussion and planning in the Dockershim Removal Kubernetes Enhancement Proposal.
Additionally, features that were largely incompatible with the dockershim, such as cgroups v2 and user namespaces are being implemented in these newer CRI runtimes. Removing support for the dockershim will allow further development in those areas, therefore it has been decided that from now on kubernetes will no longer support the docker container runtime.
Don’t panic! Docker containers and images are still alive. The depreciation of the Docker CRI inside Kubernetes will not affect the existing images, container registry and build processes.
The images produced from
docker build will work with all CRI implementations. All your existing images will still work exactly the same.
You can still use docker in your desktop to test and build images, it will not change anything for you.
If you are using a managed Kubernetes cluster such as AKS or EKS, you don’t have to worry about it, is your Cloud Service Provider that will make the changes to the master nodes and then you can decide when to upgrade your Kubernetes Cluster.
However if you have a non managed cluster, is it time to start planning your migration to the new Kubernetes version.
So Docker is (not really) Dead, Long Live Containers!