<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Yaniv Tzur on Medium]]></title>
        <description><![CDATA[Stories by Yaniv Tzur on Medium]]></description>
        <link>https://medium.com/@yaniv-tzur?source=rss-75e0feb4841a------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*wG471Nguk-dtPxL8P951zQ.jpeg</url>
            <title>Stories by Yaniv Tzur on Medium</title>
            <link>https://medium.com/@yaniv-tzur?source=rss-75e0feb4841a------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 06:06:10 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@yaniv-tzur/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Deprecation of Docker as a Container Runtime in Kubernetes 1.20 — Implications]]></title>
            <link>https://yaniv-tzur.medium.com/deprecation-of-docker-as-a-container-runtime-in-kubernetes-1-20-implications-beacdaf5ce13?source=rss-75e0feb4841a------2</link>
            <guid isPermaLink="false">https://medium.com/p/beacdaf5ce13</guid>
            <category><![CDATA[cri]]></category>
            <category><![CDATA[containers]]></category>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[kubernetes]]></category>
            <category><![CDATA[oci]]></category>
            <dc:creator><![CDATA[Yaniv Tzur]]></dc:creator>
            <pubDate>Sat, 26 Dec 2020 15:45:49 GMT</pubDate>
            <atom:updated>2020-12-29T03:43:08.441Z</atom:updated>
            <content:encoded><![CDATA[<h3>Deprecation of Docker as a Container Runtime in Kubernetes 1.20 — Implications</h3><p>Recently, the Kubernetes development team has <a href="https://kubernetes.io/blog/2020/12/02/dont-panic-kubernetes-and-docker/">announced</a> that Docker has been deprecated as a container runtime, and that it plans to remove support for it entirely in late 2021.</p><p>To begin with, I will describe how Docker fits into the complex distributed system that is Kubernetes. Generally speaking, the smallest atomic workload that can be run on a Kubernetes cluster is a pod. Each pod is scheduled by the Kubernetes scheduler to a particular worker node (physical or virtual machine).</p><p>On each worker node, a process called the <a href="https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet/">kubelet</a> is running. The kubelet receives a set of PodSpec resources through one of several mechanisms, mainly through the API server. For each of these, the kubelet makes sure that the containers corresponding to each PodSpec are running.<br>As for the pod itself, each pod consists of one or more containers. Each container is executed by a container runtime installed on the node. <a href="https://kubernetes.io/docs/setup/production-environment/container-runtimes/">Common container runtimes</a> used on Kubernetes nodes include Docker (still), containerd and CRI-O.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/812/1*AQr5n_wis9z1oUgHqOLlYA.png" /><figcaption>Container Execution Flow on Kubernetes Using Docker</figcaption></figure><p>In an <a href="https://kubernetes.io/blog/2016/12/container-runtime-interface-cri-in-kubernetes/">earlier stage</a> of Kubernetes, communication between the kubelet and container runtimes officially supported by Kubernetes was deeply integrated into the kubelet’s source code, making the integration of new container runtimes into Kubernetes difficult. In 2016, in Kubernetes 1.5, the Kubernetes development team released the Container Runtime Interface (CRI). The CRI is a clearly defined, gRPC API which a container runtime must provide if it is to be used by the kubelet to run containers. This allows to develop container runtimes without requiring a deep knowledge of the kubelet’s internals.</p><p>Now, we come to the part where we describe the considerations as to why Docker has been deprecated as a container runtime for Kubernetes. The CRI has <a href="https://www.threatstack.com/blog/diving-deeper-into-runtimes-kubernetes-cri-and-shims">standardized expectations</a> of a compatible runtime. The three most fundamental of these are that the runtime can both start and stop pods, can start, stop, kill and delete containers, and that it provides container image management.</p><p>With respect to these expectations, Docker has two main drawbacks. To begin with, Docker is much more than a container runtime. Docker is an entire technological stack, which consists of additional functionalities such as image building, and human-friendly UX features (e.g. a CLI), which are useful for a human user of Docker, but are entirely redundant for the kubelet’s needs. The main two components in Docker that are actually required by the kubelet are containerd, which is a “high-level” container runtime that is CRI-compliant, and runc, which is a “low-level” container runtime solely used to actually run containers. This brings us to the second drawback. In practice, the kubelet only needs containerd and the accompanying low-level container runtime runc. However, Docker itself is not CRI-compliant, and therefore, in order to eventually get at what the kubelet actually needs, which is to interact with containerd, an additional tool called dockershim is maintained by the Kubernetes development team.</p><p>The need to maintain an additional tool, <a href="https://pkg.go.dev/k8s.io/kubernetes/pkg/kubelet/dockershim">dockershim</a>, places an additional burden on the Kubernetes development team which is mostly unnecessary, since it contrasts the whole reason the CRI was created. This prompted the Kubernetes development team to announce the deprecation of dockershim, in favor of a CRI-compliant runtime, such as containerd or CRI-O.</p><p>Next, I discuss the implications of this change. For users of a Kubernetes cluster, the change is transparent, and therefore users shouldn’t worry about it. That’s of course assuming each node already has a CRI-compliant container runtime, but that’s something that should be handled by the administrator of the cluster. By “users”, I refer to people who deploy containers in pods on a Kubernetes cluster from ready-made images. As for developers who are used to building Docker images, pushing them to a registry, and then using those to deploy containers in pods, the change is also transparent. The reason is that “Docker images” are in fact not Docker specific but rather comply with a well established container image specification, called the OCI image specification.</p><p>Therefore, there are mainly two kinds of people who should make preparations following the deprecation of dockershim and its future planned removal. The first kind is the administrators of a Kubernetes cluster, e.g. DevOps, who need to make sure that each node is already running a CRI compliant runtime. The second type is the one which relies for some reason on the container runtime running on a node being specifically Docker. In these cases, failing to prepare properly in time, and then for example upgrading to Kubernetes 1.23 (when dockershim support is currently slated to first be removed), should prevent new containers from being run and possibly disrupt the operation of existing containers. If you belong to one of these two groups, I strongly suggest you make the necessary preparations as soon as possible, to prevent any disruption of your workloads.</p><p>As a last note, I will make a small reservation on what I wrote so far. Shortly after the announcement about the deprecation of dockershim, Mirantis <a href="https://www.mirantis.com/blog/mirantis-to-take-over-support-of-kubernetes-dockershim-2/">announced</a> that it would take over the maintenance of dockershim in cooperation with Docker Inc., only that it would be maintained as a separate component outside the kubelet process. For clusters currently using Docker as a container runtime, this will still require some configuration change to ensure a smooth transition, but according to Mirantis it should be relatively small and easy.</p><p><strong>References:</strong></p><p>[1] Don’t Panic: Kubernetes and Docker, Kuberenetes, <a href="https://kubernetes.io/blog/2020/12/02/dont-panic-kubernetes-and-docker/">https://kubernetes.io/blog/2020/12/02/dont-panic-kubernetes-and-docker/</a><a href="https://kubernetes.io/blog/2020/12/02/dont-panic-kubernetes-and-docker/"><br></a>[2]<strong> </strong>Kubernetes Container Runtimes, Kubernetes, <a href="https://kubernetes.io/docs/setup/production-environment/container-runtimes/">https://kubernetes.io/docs/setup/production-environment/container-runtimes/</a><br>[3] Kubelet, Kubernetes, <a href="https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet/">https://kubernetes.io/docs/reference/command-line-tools-reference/kubelet/</a><br>[4] CRI, Kubernetes, <a href="https://kubernetes.io/blog/2016/12/container-runtime-interface-cri-in-kubernetes/">https://kubernetes.io/blog/2016/12/container-runtime-interface-cri-in-kubernetes/</a><br>[5] Diving Deeper Into Runtimes: Kubernetes, CRI, and Shims, Threat Stack, <a href="https://www.threatstack.com/blog/diving-deeper-into-runtimes-kubernetes-cri-and-shims">https://www.threatstack.com/blog/diving-deeper-into-runtimes-kubernetes-cri-and-shims</a><br>[6] dockershim source code documentation, <a href="https://pkg.go.dev/k8s.io/kubernetes/pkg/kubelet/dockershim">https://pkg.go.dev/k8s.io/kubernetes/pkg/kubelet/dockershim</a><br>[7] Mirantis to take over support of Kubernetes dockershim, Mirantis, <a href="https://www.mirantis.com/blog/mirantis-to-take-over-support-of-kubernetes-dockershim-2/">https://www.mirantis.com/blog/mirantis-to-take-over-support-of-kubernetes-dockershim-2/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=beacdaf5ce13" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>