Learning Path: Certified Kubernetes Application Developer (CKAD) Prep Course
Source of these Notes
📌 TABLE OF CONTENTS
Get information about a particular API Object
kubectl explain pods.spec
kubectl create --help
Alias kubectl alias
alias k=kubectl
Setting current context
kubectl config set-context <context-of-question> --namespace=<namespace of question>
Delete all objects forcefully
kubectl delete pods <pod-name> --force
Imperative Approach
kubectl run nginx --image=nginx --restart=Never
Declarative Approach - create a yaml file and then execute kubectl apply -f
Hybrid approach - generate a yaml file from imperative approach
kubectl run nginx --image=nginx --restart=Never --dry-run=client -o yaml > output.yaml
--dry-run=client
does not create an actual resource
Kubernetes uses
etcd
datastore to store data
Control flow
kubectl
➡️ API Server
➡️ etcd
➡️ Scheduler
➡️ Kubelet
➡️ Pod
➡️ Docker