Table of contents
๐ Introduction :
In this blog, we will explore Kubernetes Architecture
Kubernetes Overview
With the widespread adoption of containers among organizations, Kubernetes, the container-centric management software, has become a standard for deploying and operating containerized applications and is one of the most important parts of DevOps.
Originally developed at Google and released as open-source in 2014. Kubernetes builds on 15 years of running Googleโs containerized workloads and the valuable contributions from the open-source community. Inspired by Googleโs internal cluster management system.
๐ผTasks
What is Kubernetes?
Kubernetes is an open-source platform that automates the deployment, scaling, and management of containerized applications. It was designed to simplify the process of running and managing containers in large-scale, multi-node environments.
why do we call it k8s?
The name "k8s" is simply a shorthand for "Kubernetes". The number 8 represents the number of letters skipped between the "K" and the "s" in the word "Kubernetes".
What are the benefits of using k8s?
The benefits of using Kubernetes (k8s) :
Run applications in containers efficiently.
Keep applications up and running even if a node fails.
Easily deploy and update applications.
Scale applications to meet demand.
Improve security for applications.
Run applications in different environments with ease.
Explain the architecture of Kubernetes
The architecture of Kubernetes consists of several main components:
Master Node: The "brain" of the Kubernetes cluster, the master node oversees the entire system's operation. It consists of several key components:
API Server: Acts as the central control point, allowing users and components to interact with the cluster via RESTful API calls.
Scheduler: Decides where to deploy newly created pods based on available resources, node conditions, and various constraints.
Controller Manager: Watches the state of the cluster and works to maintain the desired state, reacting to changes and failures.
etcd: A distributed key-value store that stores the cluster's configuration data and state. It acts as Kubernetes' "memory."
Node (Worker Node): These are the worker machines where containers are deployed and executed. Each node runs the following components:
Kubelet: Acts as the node's "agent," responsible for communicating with the master node and managing containers on the node.
Kube Proxy: Maintains network rules for pod-to-pod communication and load balancing across service endpoints.
Pods: The smallest deployable unit in Kubernetes, a pod is a logical group of one or more containers that share the same network and storage resources. Containers within the same pod can communicate easily using localhost
Services: Services provide a consistent way to expose and access pods, allowing them to communicate with each other within the cluster or to external systems.
What is a Control Plane?
The Control Plane manages the worker nodes and the Pods in the cluster. In production environments, the control plane usually runs across multiple computers and a cluster usually runs multiple nodes, providing fault-tolerance and high availability. Components of the control Plane include API server, etcd, scheduler, and controller manager.
What is the difference between kubectl and kubelets?
kubectl:
A command-line tool used for managing Kubernetes clusters.
Runs on your local machine or management server.
Communicates with the Kubernetes API server to send commands and receive cluster information.
Manages and controls the entire Kubernetes cluster.
Versatile for different cluster environments.
kubelet:
A node-level agent that runs on each worker node within the cluster.
Runs on every worker node.
Communicates with the Control Plane, including the API server and other components.
Integrates with the selected container runtime (e.g., Docker) to manage container lifecycles.
Monitors pod health and reports to Control Plane.
Explain the role of the API server
The API server is a critical component of the Kubernetes control plane that exposes the Kubernetes API, handles authentication and authorization, provides admission control, manages the state of Kubernetes resources, and supports horizontal scaling of the control plane.
๐ Conclusion :
In this blog, we cover Kubernetes Architecture & Kubernetes components, we will cover some advanced topics.
Thank you for reading!
Contact me on Linkedin ๐ค
Check out my GitHub for more resources ๐