Container orchestration engine for automating deployment, scaling, and management of containerized applications.
What are Microservices?
What is container?
What is Containerization?
What is Docker?
2. We Should know following terms before proceeding to Kubernetes :
1. What are Microservices?
2. What is container?
3. What is Containerization?
4. What is Docker?
3. What are Microservices ?
Microservices are an architectural approach to application
development where software is composed of small
independent services that communicate over well-defined APIs.
Microservices are used in application development because of
following advantages:
1. Increased scalability.
2. Optimize business functionality.
3. Continuous delivery/continuous integration.
4. Language Independent.
4. What is Container ?
A container is a standard unit of software that
packages up code and all its dependencies so the
application runs quickly and reliably.
Containers require less system resources than
traditional or hardware virtual machine environments
because they don't include operating system images.
Data volumes can be shared among multiple
containers.
Portable and platform independent: Containers carry
all their dependencies with them
For e.g. Developer can transfers code from a desktop
computer to a virtual machine (VM) or from a Linux to
a Windows operating system.
5. Containerization is a type of virtualization in which all the components of an application are bundled into a single
container image and can be run in isolated user space on the same shared operating system. Containers are
lightweight, portable.
What is Containerization ?
6. What is Docker ?
Docker is an open platform for developing, shipping,
and running applications.
Docker enables you to separate your applications
from your infrastructure so you can deliver software
quickly.
A Docker file is simply a text-based script of
instructions that is used to create a container image.
Docker Hub is used to share container image among
other for deployment as well for QA.
7. KUBERNETES or K8s
Kubernetes is a portable, extensible, open-source platform for managing containerized workloads and services, that
facilitates both declarative configuration and automation.
It can run and coordinate containerized applications across a cluster of machines.
It is a platform designed to completely manage the life cycle of containerized applications and services using
methods that provide predictability, scalability, and high availability.
Kubernetes can define how your applications should run and how application interact with other applications or
the outside world.
8. Why you need Kubernetes?
Managing containers is a challenge, especially when you have
to deal with dozens or even hundreds of containers because
• Ensure there is no downtime.
• Need to be deployed ,managed and updated.
Kubernetes do following things :
Load Balancing
High Availabilty or No Downtime
Automated Rollbacks
Auto healing
Logging and Monitoring
10. A Kubernetes cluster is a set of nodes that run containerized applications.
Nodes are the machines on Kubernetes. They can be either a physical or a virtual machine.
Pods are composed of a group of one or more containers, the shared storage for them and their options.
Deployments are used to make updates on Pods. We can use them to bring up new Pods, change the
image version of a container and even recreate the previous state if something goes wrong.
Kubernetes Key Concepts
11. Kubernetes Master Node
API Server is the entry point that Kubernetes CLI ( kubectl ) taks to when you are creating Kubernetes
resources or managing the cluster
Scheduler component works together with the API server to
schedule the applications or workloads on to the worker nodes
and also gathers information about resources available to decide
to assign new client request to which worker node.
Controller Manager is responsible for running different types of
controllers that maintain the overall desired state of the cluster.
All the controllers are packaged and shipped in the kube-
controller-manager.
Controllers keep track of what workloads are running, the nodes
that they’re running on, the resources available to those
deployed workloads, and the policies around how they should
behave.
etcd stores the configuration of the Kubernetes cluster in etcd. It
also stores the actual state of the system and the desired state of
the system in etcd
12. Kubernetes Worker Node
Worker nodes within the Kubernetes cluster are used to run containerized applications and handle networking to
ensure that traffic between applications across the cluster and from outside of the cluster can be properly
facilitated.
Worker Node Consists of :
Kubelet is an agent that runs on each node
in the cluster. It makes sure that containers
are running in a Pod.
Container Runtime also known as
container engine, is a software component
that can run containers on a host
operating system.
Kube-Proxy is a network proxy that runs
on each node in your cluster,
implementing and maintains network rules
on nodes.
13. DNS: All Kubernetes clusters should have cluster DNS; it is a mandatory feature. Cluster DNS is a DNS server, in
addition to the other DNS server(s) in your environment, which serves DNS records for Kubernetes services.
Web UI: This is a general purpose, web-based UI for Kubernetes clusters. It allows users to manage and troubleshoot
applications running in the cluster, as well as the cluster itself.
Container Resource Monitoring: Providing a reliable application runtime, and being able to scale it up or down in
response to workloads, means being able to continuously and effectively monitor workload performance. Container
Resource Monitoring provides this capability by recording metrics about containers in a central database, and
provides a UI for browsing that data
Cluster-level logging: Logs should have a separate storage and lifecycle independent of nodes, pods, or containers.
Otherwise, node or pod failures can cause loss of event data. The ability to do this is called cluster-level logging, and
such mechanisms are responsible for saving container logs to a central log store with search/browsing interface.
Add-ons