kubedump is a tool for dumping manifests from your Kubernetes clusters. It’s highly inspired by the available shell scripts (1, 2) and just a Go implementation with similar behaviour I wrote mostly for fun.
A clear drawback of the Go implementation is the enormous binary size for such small functionality. Currently, the code is not even 200 lines of code but due to the imports from the Kubernetes ecosystem, the binary is around 30 MB. Nevertheless, having a binary instead of a shell script might have other benefits, e.g. no other required dependencies and compared to the scripts it seems to be very fast.
Make sure to check the repository for the latest version.
Binaries are available for all major platforms. See the releases page.
Using the Homebrew package manager for macOS:
brew install sj14/tap/kubedump
It’s also possible to install via
go get -u github.com/sj14/kubedump
Usage of kubedump:
dump cluster-wide resources (default true)
path to the kubeconfig (default "~/.kube/config")
context from the kubeconfig, empty for default
output directory for the dumps (default "dump")
namespace to ignore (e.g. 'ns1,ns2')
resource to ignore (e.g. 'configmaps,secrets')
dump namespaced resources (default true)
namespace to dump (e.g. 'ns1,ns2'), empty for all
resource to dump (e.g. 'configmaps,secrets'), empty for all
remove fields containing a state of the resource (default true)
maximum number of threads (minimum 1) (default 10)
output the current progress
print version information of this release