Skip to content

Simple bash script to dump all useful kubernetes configs to yaml files (except secrets because well, they are secret)

Notifications You must be signed in to change notification settings

graciousagency/kubedump

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

kubedump

Your one-stop command to dump kubernetes configs to files. We use this to add our configs to git for safe-keeping.

Installation

Check it out, move it to /usr/local/bin/kubedump and chmod +x it

git clone https://github.com/graciousagency/kubernetes-dump.git
cd kubernetes-dump
mv kubedump /usr/local/bin/
chmod +x /usr/local/bin/kubedump

Usage

Now if you run it when you have a cluster configured it will dump the following resources. They are placed in subdirectories matching the resource type.

  • configmap
  • cronjob
  • deployments
  • horizontalpodautoscalers
  • ingresses
  • limitranges
  • persistentvolumeclaims
  • persistentvolumes
  • services
  • statefulset

Notes

  • Ingresses are exported in a seperate loop WITHOUT --export to preserve the ip they are currently using
  • You must have kubectl installed
  • I highly recommend using kubectx to switch between projects easily

About

Simple bash script to dump all useful kubernetes configs to yaml files (except secrets because well, they are secret)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages