- Take me to Practice Test
-
Run the command
kubectl get pods
and count the number of pods.$ kubectl get pods
-
Run the command
kubectl run nginx --image=nginx
$ kubectl run nginx --image=nginx
-
Run the command
kubectl get pods
and count the number of pods.$ kubectl get pods
-
Run the command **
kubectl describe pod newpods**
' look under the containers section.$ kubectl describe pod newpods
-
Run the command
kubectl describe pod newpods
orkubectl get pods -o wide
look under the containers section.$ kubectl describe pod newpods
-
Run the command
kubectl describe pod webapp
and look under the Containers section (or) Runkubectl get pods
and look under the READY section$ kubectl describe pod webapp
-
Run the command
kubectl describe pod webapp
and look under the containers section.$ kubectl describe pod webapp
-
Run the command
kubectl describe pod webapp
and look under the containers section.$ kubectl describe pod webapp
-
Run the command
kubectl describe pod webapp
and look under the events section.$ kubectl describe pod webapp
-
Run the command
kubectl get pods
$ kubectl get pods
-
Run the command
kubectl delete pod webapp
$ kubectl delete pod webapp
-
Create a pod definition YAML file and use it to create a POD or use the command
kubectl run redis --image=redis123
$ kubectl run redis --image=redis123
-
Now fix the image on the pod to
redis
. Update the pod-definition file and usekubectl apply
command or usekubectl edit pod redis
command.$ kubectl apply $ kubectl edit pod redis