2. THE NEED FOR CONTAINER
ORCHESTRATION
Docker
packaging, deploying and running containerized application
applications are independent of the underlying OS architecture.
Docker itself can be used to manage a few containers running on a
fewer machines.
Production applications deploy containers on a large scale on
hundreds of machines.
3. THE NEED FOR CONTAINER
ORCHESTRATION
PHYSICAL INFRASTRUCURE
VM VM VM VMVM VM VMVM
CLUSTER CLUSTER
CLUSTERCLUSTERCLUSTER
CLUSTER MANAGER
4. WHAT IS KUBERNETES
A subset of an internal Google project called Borg.
Decouples application from machines through containers.
Maintains and tracks the global view of the cluster.
Distributed architecture with master and multiple worker nodes.
Developed in Go language.
Automate the scaling and distribution of applications.
5. K8S FEATURES
Horizontal scaling – with command or based on CPU usage.
Self-healing – restart containers that fail or don`t respond to health
check. Replaces and reschedules containers when nodes die.
Automating binpacking – placing the containers based on their
resource requirements thus saving system resource.
Automated rollouts and rollbacks - If something goes wrong,
Kubernetes will rollback the changes.
Storage orchestration – mount the storage system of your choice
from local storage or AWS or from a network storage system.
7. KUBERNETES COMPONENTS
Master - coordinates the cluster
Cluster - set of physical or virtual machines and other infrastructure
resources used by Kubernetes to run your applications.
Nodes – hosts that run kubernetes applications.
Pod - a co-located group of containers and volumes. Unit of
deployment.
Label - a key/value pair for identification.
Replication Controller – ensures/maintains availability and
scalability.
etcd – maintains state.
8. CREATING A CLUSTER
A k8s cluster consists of two types of resources
The Master coordinates the cluster
Nodes are the workers that runs application.
The nodes communicate with the master using the Kubernetes
API, which the master exposes.
9. CREATE A DEPLOYMENT
A Deployment is responsible for
creating and updating instances of application.
The Deployment controller replaces an instance
if the Node hosting it goes down or it is deleted.
10. PODS AND NODES
A Pod is a group of one or more application
containers and includes shared storage (volumes),
IP address and information about how to run them.
11. PODS AND NODES
Every Kubernetes Node runs at least:
Kubelet, a process responsible for communication
between the Kubernetes Master and the Nodes
A container runtime (like Docker, rkt).