Skip to content

Instantly share code, notes, and snippets.

@chadmcrowell
Created October 18, 2023 18:56
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chadmcrowell/ac999796aa59e2d6ba2286b649a0188f to your computer and use it in GitHub Desktop.
Save chadmcrowell/ac999796aa59e2d6ba2286b649a0188f to your computer and use it in GitHub Desktop.
Dallas Kubernetes Workshop - Warmup
# perform the commands from the following site:
# https://studyk8s.club/cka-warmup
# list all the api resources
k api-resources
# help menu is your friend
k -h
# help menu goes many levels deep
k config -h
# get your current context
k config get-contexts
# list the status of the kubelet service
systemctl status kubelet
# show namespaces
k get ns
# create a namespace
k create ns cka
# list the pods in the kube-system namespace
k -n kube-system get po
# typing the namespace first will help with autocomplete
k -n kube-system get po kube-{press-tab-to-autocomplete-the-pod-name} -o yaml
# create a pod YAML file with --dry-run=client
k run nginx --image nginx --dry-run=client -o yaml > pod.yaml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment