Skip to main content
Ganesh Joshi
Back to Cheatsheets

kubectl commands

Updated 2026-02-15

kubectl for Kubernetes: get, describe, apply, logs, exec. Pods, deployments, and services.

Get and describe

  • kubectl get pods

    List pods.

  • kubectl get pods -A

    All namespaces.

  • kubectl describe pod <name>

    Pod details.

  • kubectl get svc,deploy

    Services and deployments.

Apply, logs, exec

  • kubectl apply -f file.yaml

    Apply manifest.

  • kubectl logs <pod> -f

    Follow logs.

  • kubectl exec -it <pod> -- sh

    Shell into pod.

  • kubectl delete pod <name>

    Delete pod.

kubectl commands | Cheatsheet | Ganesh Joshi