In this chapter we walk you through the Kubernetes API basics. This includes a deep dive into the API server’s inner workings, the API itself, and how you can interact with the API from the command line. We will introduce you to Kubernetes API concepts such as resources and kinds, as well as grouping and versioning.
Kubernetes is made up of a bunch of nodes (machines in the cluster) with different roles, as shown in Figure 2-1: the control plane on the master node(s) consists of the API server, controller manager, and scheduler. The API server is the central management entity and the only component that talks directly with the distributed storage component
The API server has the following core responsibilities:
To serve the Kubernetes API. This API is used cluster-internally by the master components, the worker nodes, and your Kubernetes-native apps, as well as externally by clients such as
To proxy cluster components, such as the Kubernetes dashboard, or to stream logs, service ports, or serve
kubectl exec sessions.
Serving the API means:
Reading state: getting single objects, listing them, and streaming changes
Manipulating state: creating, updating, and deleting objects
State is persisted via
The heart of Kubernetes is its API server. But how does ...