Posts

Showing posts from November, 2023

lables,selector,replicaset,deploymentset

 Labels:- Labels are the mechanism to organize Kubernetes objects such as Pods   A label is a key-value pair. Labels can be attached to objects at creation time or added and modified at any time.    "metadata" : { "labels" : { "key1" : "value1" , "key2" : "value2" } } To create lables imperative we can use kubectl label pods delhipod myname=ajay  // delhipod is pod name  to check the lables  kubectl get pods --show-labels // to show the lables of pods  To get the pods where env is not equal to development  kubectl get pods -l env!=development   // We need to use ! sign before key (env is key hear) We can also delete the pods using lables kubectl delete pod -l env!=development   Labels Selector Once the lables are attached to an object, we would need filters to narrow down and these are called as labels selector The API currently supports two types of selector -  1 equality based  ( =, !=)...

Kuberntes architecture

Image
 Differnce between docker and kuberntes kuberntes have  cluster management  autoscaling autohealing enterprise application support like loadbalancing , fariewall  Docker shim is container runtime in docker to run containers  The smallest unit of deployment in docker is container The smallest unit of deployment in kuberntes is pod Kublete :-  The Kubelet is responsible for  managing the deployment of pods to Kubernetes nodes What Is a Container Runtime? A container runtime, also known as container engine, is a software component that can run containers on a host operating system. In a  containerized architecture , container runtimes are responsible for loading container images from a repository, monitoring local system resources, isolating system resources for use of a container, and managing container lifecycle.  Common container runtimes commonly work together with container orchestrators. The orchestrator is responsible for managing cluster...