Kubernetes
Jump to navigation
Jump to search
This page is about Kubernetes, often abbreviated to K8s, a container orchestration system.
Kubernetes can be viewed as the next step after Docker Compose. Docker Compose runs multiple containers on one machine, whereas Kubernetes assembles several machines into a cluster and manages the container distribution to those machines as well as running the containers in this distributed system.
For basics on containers and images and how to run them singly, or with a compose system, see the Podman page on this wiki.
References
Glossary
- Cluster
- The entire system managed by one Kubernetes instance. A cluster consists of one or more → nodes.
- Container
- The lowest level thing in a → cluster that does work. A container is located inside a → pod.
- Control Plane node
- The → node that runs the Control Plane is responsible for managing the entire → cluster. A cluster can have more than one Control Plane node, making it a → High Availability cluster. Instead of "Control Plane node", this is often simplified to just "Control Plane".
- High Availability Cluster
- A → cluster that has more than one → Control Plane node. In a cluster that has only one Control Plane node, if that node goes down the entire cluster can no longer be managed. Multiple Control Plane nodes are used to guard against such an outage. Usually an odd number of Control Plane nodes is used (1, 3, 5, ...) because of the mechanisms that are used to coordinate the nodes.
- Label
- A key-value pair that is attached to a Kubernetes API object, such as a → pod or a → node.
- Node
- One machine, either physical or virtual. Nodes are classified into → Control Plane nodes and → Worker nodes.
- Pod
- The basic scheduling unit in Kubernetes. A pod consists of one or more → containers that are guaranteed to be located on the same → node. Every pod is assigned a unique IP address within the → cluster. Within the pod, all containers can reference each other.
- Service
- A set of → pods that work together. The set of pods that constitute a service are defined by a → label selector.
- Worker Node
- A → node that performs some work in the → cluster. A cluster usually has at least 1 worker node, because work should not be done on the → Control Plane node(s).
- Workload
- A higher level abstraction of work than a → pod. Kubernetes supports several such abstractions. Examples: ReplicaSet, StatefulSet, DaemonSet.
Control plane
Components that run on the control plane:
- etcd: Key-value data store that contains the configuration data of the cluster.
- API server: Provides a REST API that other parts of the system can use to access the data stored by etcd.
- Scheduler: Selects the node where a pod should run on, based on resource availability and other constraints. The scheduler's role is to match resource "supply" to workload "demand".
Worker node
TODO
Do something with the following links:
- Compose to Kubernetes: https://rfaes-com.github.io/compose-to-kubernetes/
- https://github.com/containers/crun
- https://github.com/youki-dev/youki
- https://cri-o.io/
- https://github.com/cri-o/cri-o
- https://kubernetes.io/docs/concepts/containers/cri/
- https://kubernetes.io/docs/reference/networking/virtual-ips/