Skip to main content

CKAD

“The Certified Kubernetes Application Developer exam certifies that users can design, build, configure, and expose cloud native applications for Kubernetes.”

Resources

Utilities

Recent Commands

kubectl -n openfaas get deployments -l “release=openfaas, app=openfaas”
kubectl rollout status -n openfaas deploy/gateway
kubectl port-forward -n openfaas svc/gateway 8080:8080 &
kubectl proxy

Home Environment

kubectl proxy

Imperative Commands

--dry-run

By default as soon as the command is run, the resource will be created. If you simply want to test your command, use the --dry-run=client option. This will not create the resource, instead, tell you whether the resource can be created and if your command is right.

-o yaml

This will output the resource definition in YAML format on the screen.

Examples

kubectl run nginx-pod --image=nginx:alpine
kubectl run redis --image=redis:alpine --labels=tier-db
kubectl expose pod redis --name redis-service --port 6379 --target-port 6379
kubectl describe svc redis-service
kubectl create deploynment webapp --image=kodekloud/webapp-color
kubectl scale deployment --replicas=3
kubectl run custom-nginx --image-nginx --port 8080
kubectl describe pod custom-nginx
kubectl create ns dev-ns
kubectl create deployment redis-deploy --image=redis --namespace=dev-ns
kubectl run httpd --image=httpd:alpine --port 80 --expose --dry-run=client -o yaml
kubectl run httpd --image=httpd:alpine --port 80 --expose
kubectl get pod httpd