Back to Glossary
Kubernetes

What is kubectl?

The command-line tool for interacting with Kubernetes clusters.

kubectl is the primary CLI for communicating with a Kubernetes cluster's API server. Common commands: get (list resources), describe (detailed resource info), apply (create/update from YAML), delete, exec (run command in pod), logs, port-forward (forward local port to pod), and rollout (manage deployment rollouts). kubectl reads kubeconfig (~/.kube/config) for cluster credentials. Speed tips: alias k=kubectl, use --dry-run=client -o yaml to generate YAML templates.

Test your knowledge of kubectl and 130 other DevOps concepts