Skip to content

Instantly share code, notes, and snippets.

@jalamprea
Created February 20, 2020 21:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jalamprea/f2da9c0f228415515d15453ab2a603b0 to your computer and use it in GitHub Desktop.
Save jalamprea/f2da9c0f228415515d15453ab2a603b0 to your computer and use it in GitHub Desktop.
for n in $(kubectl get -o=name pvc,configmap,serviceaccount,secret,ingress,service,deployment,statefulset,hpa,job,cronjob)
do
mkdir -p $(dirname $n)
kubectl get -o=yaml --export $n > $n.yaml
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment