Kubernetes Commands

The following lists some useful commands for getting information and debugging the system. Make sure you understand them before using.

Command

Description

kubectl cluster-info

Prints information about the running Kubernetes cluster.

kubectl get all

Lists all the components running in the Kubernetes cluster.

kubectl describe <pod|service>

Describe a pod or service.

kubectl exec -it <pod> /bin/sh

Run an interactive shell inside one of the pods.

kubectl run curl image=radial/busyboxplus:curl –i --tty

Run a container in the cluster with curl installed to inspect the network

kubectl describe svc <service>

Describe a service, including what pods back it.

minikube dashboard

Enables the Minikube dashboard that displays the health of the deployment.

minikube kubectl logs <pod|service>

Displays the log for a pod or service.

minikube service <service> --url -n ess

Get the services URL from the host.

See also: