0
0
Kubernetesdevops~10 mins

kubectl delete for removal in Kubernetes - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the command to delete a pod named 'my-pod'.

Kubernetes
kubectl delete [1] my-pod
Drag options to blanks, or click blank then click option'
Apod
Bget
Capply
Dcreate
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'create' instead of 'delete' to remove resources.
Forgetting to specify the resource type like 'pod'.
2fill in blank
medium

Complete the command to delete a deployment named 'web-app'.

Kubernetes
kubectl delete [1] web-app
Drag options to blanks, or click blank then click option'
Aservice
Bconfigmap
Cdeployment
Dnode
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'service' or 'node' instead of 'deployment' for deleting deployments.
Misspelling the resource name.
3fill in blank
hard

Fix the error in the command to delete a service named 'backend'.

Kubernetes
kubectl [1] service backend
Drag options to blanks, or click blank then click option'
Acreate
Bget
Cdescribe
Ddelete
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'create' or 'get' instead of 'delete' to remove resources.
Omitting the resource type 'service'.
4fill in blank
hard

Fill both blanks to delete a configmap named 'app-config' in the 'dev' namespace.

Kubernetes
kubectl delete [1] app-config -n [2]
Drag options to blanks, or click blank then click option'
Aconfigmap
Bpod
Cdev
Dprod
Attempts:
3 left
💡 Hint
Common Mistakes
Using wrong resource type like 'pod' instead of 'configmap'.
Using the wrong namespace name.
5fill in blank
hard

Fill all three blanks to delete a pod named 'cache-pod' with a grace period of 0 seconds.

Kubernetes
kubectl delete [1] cache-pod --grace-period=[2] --force=[3]
Drag options to blanks, or click blank then click option'
Apod
B0
Ctrue
Dfalse
Attempts:
3 left
💡 Hint
Common Mistakes
Using a non-zero grace period when immediate deletion is needed.
Setting force to false or omitting it.