Home>Article>Operation and Maintenance> What is the relationship between docker and k8s?
1. First, let’s take a look at the official definitions of docker and k8s:
Docker is an open source application container engine that allows developers to package their applications and Dependencies are put into a portable container and distributed to popular Linux machines, which can also be virtualized.
(Recommended tutorial:docker)
k8s is an open source container cluster management system that can realize automatic deployment, automatic expansion and contraction, and maintenance of container clusters. .
2. Next, let’s take a look at the comparison between the two and traditional technologies:
1. From the perspective of virtualization
Traditional virtual technology will After physical hardware is virtualized into multiple sets of hardware, an operating system needs to be deployed on each set of hardware, and then corresponding applications are run on these operating systems.
The application process in the Docker container runs directly on the kernel of the host (real physical machine). The Docker engine packages some independent applications and their respective dependencies, and runs them independently on the future. On virtualized host hardware, each container does not have its own kernel, which is obviously lighter than traditional virtual machines.
Each cluster has multiple nodes, and each node can be used. Our kuberbete is designed to manage the small operating environment (container) where these applications are located.
2. From a deployment perspective
The traditional method is to deploy all applications directly on the same physical machine node. In this way, the dependencies of each App are exactly the same, and it is impossible to achieve the same goal between Apps. Of course, for isolation, we can also create a virtual machine to deploy the App to it, but this is too cumbersome.
Now we deploy applications through the technology of deploying Container containers, and all Containers can run on the container engine.
Since you dislike the heavy workload of virtual machines and want to use Docker, fine, go ahead and use it. How to use it? Create one by one manually? Of course not, so kubernetes technology appeared, and the container cluster management system represented by kubernetes was about to come on stage.
3. Finally, let’s analyze the relationship between docker and k8s:
We use kubernetes to manage Docker clusters, that is, Docker can be regarded as a low-level component used internally by Kubernetes.
In addition, kubernetes not only supports Docker, but also supports Rocket, which is another container technology.
The above is the detailed content of What is the relationship between docker and k8s?. For more information, please follow other related articles on the PHP Chinese website!