Concepts Flashcards
A node
A node is a machine – physical or virtual – on which kubernetes is installed. A node is a worker machine and this is were containers will be launched by kubernetes.

A minion
A node
A cluster
A cluster is a set of nodes grouped together. This way even if one node fails you have your application still accessible from the other nodes. Moreover having multiple nodes helps in sharing load as well.
The master
The master is another node with Kubernetes installed in it, and is configured as a Master. The master watches over the nodes in the cluster and is responsible for the actual orchestration of containers on the worker nodes.

Kubernetes components
An API Server. An ETCD service. A kubelet service. A Container Runtime, Controllers and Schedulers.

The API server
The API server acts as the front-end for kubernetes. The users, management devices, Command line interfaces all talk to the API server to interact with the kubernetes cluster.
ETCD
ETCD is a distributed reliable key-value store used by kubernetes to store all data used to manage the cluster. Think of it this way, when you have multiple nodes and multiple masters in your cluster, etcd stores all that information on all the nodes in the cluster in a distributed manner. ETCD is responsible for implementing locks within the cluster to ensure there are no conflicts between the Masters.
The scheduler
The scheduler is responsible for distributing work or containers across multiple nodes. It looks for newly created containers and assigns them to Nodes.
The controllers
The controllers are the brain behind orchestration. They are responsible for noticing and responding when nodes, containers or endpoints goes down. The controllers makes decisions to bring up new containers in such cases.
The container runtime
The container runtime is the underlying software that is used to run containers. In our case it happens to be Docker.
The kublet
And finally kubelet is the agent that runs on each node in the cluster. The agent is responsible for making sure that the containers are running on the nodes as expected. Kubelet is responsible for interacting with the master to provide health information of the worker node and carry out actions requested by the master on the worker nodes.
The kube command line tool
ONE of the command line utilities used to deploy and manage applications on a kubernetes cluster, to get cluster information, get the status of nodes in the cluster and many other things.
kubectl
ONE of the command line utilities used to deploy and manage applications on a kubernetes cluster, to get cluster information, get the status of nodes in the cluster and many other things.
kubectl run
Deploy an application on the cluster.
kubectl cluster-info
View information about the cluster.
kubectl get pod
List all the nodes part of the cluster.
Master vs worker nodes - worker.
Worker is were the containers are hosted.
A container runtime (Docker, Rocket, CRIO etc.)
Kubelet agent.

Minikube vs Kubeadmin vs play-with-k8s.com
A single instance of Kubernetes in an All-in-one setup vs tool used to configure kubernetes in a multi-node setup. Online.
Minikube
Minikube bundles all components into a single image providing us a pre-configured single node kubernetes cluster so we can get started in a matter of minutes.
The whole bundle is packaged into an ISO image and is available online for download. Minikube provides an executable command line utility that will AUTOMATICALLY download the ISO.
You must have a hypervisor installed, kubectl installed and minikube executable installed on your system.
Kubeadmin
The tool helps us setup a multi node cluster with master and workers on separate machines.
Kubeadmin 6 steps
- You must have multiple systems or virtual machines created for configuring a cluster.
- Install a container runtime on the hosts.
- Install kubeadmin tool on all the nodes.
- Initialize the Master server.
- POD network
- Join the worker nodes to the master node
A pod
The containers are encapsulated into a Kubernetes object known as PODs. A POD is a single instance of an application. A POD is the smallest object, that you can create in kubernetes. oneToOne or oneToMany
kubectl run nginx –image nginx
Dostęp do nginx z node / z poza
Tak / Nie

2 deployment strategies
RECREATE UPDATE First destroy all old instances and deploy newer versions - the app is down an inaccessible to users.
ROLLING UPDATE (default) destroy old and deploy new one by one - the app never goes down.
