Kubernetes for the Absolute Beginners Flashcards
What is the command to deploy a NGINX pod?
kubectl run nginx –image=nginx
What is the command to list pods?
kubectl get pods
What is the command to get more information about a pod?
kubectl describe pod <pod_name></pod_name>
What is the command to check the status of the pod with additional information?
kubectl get pods -o wide
What is the command to list nodes?
kubectl get nodes
What is the command to get verbose information about a node?
kubectl describe node
What are the 4 root or top level configurations in your pod-definition.yml?
apiVersion:
kind:
metadata:
spec:
What is the command to apply a pod.yaml file?
kubectl apply -f pod.yml
What is the command to delete a pod?
kubectl delete pod <pod_name></pod_name>
What is the command to dry run and output a pod to yaml?
kubectl run image –image=<image_name> --dry-run -o yml</image_name>
What does a replication controller do in an environment where a single pod is running and the pod fails?
Brings up a new one
What is replacing the replica controller
Replication Set
What is the command to create a replica controller from a file?
kubectl create -f <filename>.yml</filename>
What is the command to list the replication controller?
kubectl get replicationcontroller
What is the command to create a replica set from a file?
kubectl create -f <filename>.yml</filename>