## Kubectl most common commands Here are some of the most common kubectl commands : ### Cluster Status: kubectl cluster-info: Displays cluster info. kubectl get nodes: Lists nodes in the cluster and their status. kubectl get pods --all-namespaces: Lists all pods in all namespaces. kubectl get deployments: Lists all deployments in the cluster. kubectl get services: Lists all services in the cluster. ### Application Deployment and Management: kubectl create deployment --image=: Creates a new deployment. kubectl expose deployment --port=: Exposes a deployment as a service. kubectl scale deployment --replicas=: Scales a deployment to increase or decrease the number of replicas. kubectl set image deployment/ =: Updates the image of a container in a deployment. ### Debugging and Monitoring: kubectl logs : Displays logs of a specific pod. kubectl describe pod : Provides details about a specific pod. kubectl top nodes: Shows resource usage metrics for nodes. kubectl top pods: Shows resource usage metrics for pods. ### Configuration Management: kubectl create configmap --from-file=: Creates a ConfigMap from a file. kubectl create secret generic --from-literal==: Creates a secret from literal values. kubectl apply -f : Applies configuration from a YAML file. ### Resource Deletion: kubectl delete : Deletes a specific resource. kubectl delete -f : Deletes resources defined in a YAML file. kubectl delete pod --all: Deletes all pods in the cluster.