Reputation: 30723
I have a problem to understand the kubernetes workflow: So as I understand the flow:
You have a master which contains etcd, api-server, controller manager and scheduler. You have nodes which contain pods (wich contain containers), kubelet and a proxy.
The proxy is working as a basic proxy to make it possible for a service to communicate with other nodes. When a pod dies, the controller manager will see this (it 'reads' the replication controller which describes how many pods there normally are).
unclear: The controller manager will inform the API-server (I'm not right about this). The API-server will tell the scheduler to search a new place for the pod. After the scheduler has found a good place, the API will inform kubelet to create a new pod.
I'm not sure about the last scenario? Can you tell me the right proces is a clear way? Which component is creating the pod and container? Is it kubelet?
Upvotes: 1
Views: 437
Reputation: 2882
So it's the kubelet that actually creates the pods and talks to the docker daemon. If you do a docker ps -a
on your nodes (as in not master) in your cluster, you'll see the containers in your pod running. So the workflow is run a kubectl command, that goes to the API server, which passes it to the controller, say that command was to spawn a pod, the controller relays that to the API server which then goes to the scheduler and tells it to spawn the pod. Then the kubelet is told to spawn said pod.
I suggest reading the Borg paper that Kubernetes is based on to better understand things in further detail. http://static.googleusercontent.com/media/research.google.com/en//pubs/archive/43438.pdf
Upvotes: 3