manifest-splitter

command module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 17, 2022 License: Apache-2.0 Imports: 18 Imported by: 0

README

manifest-splitter

This is a super simple tool that can be used to split up Kubernetes manifests into directories named after the namespace they exist within.

This is great for users using Anthos Config Management, which requires all manifests to be sorted into namespace-named directories.

Support level

This is a pet-project, created to serve my own needs. Whilst others may find it useful, this is not a product and I will not be able to provide timely responses.

Usage

To run the manifest splitter, a Kubernetes apiserver must be available in order to determine whether a given resource is namespace or cluster scoped.

To run the manifest-splitter and split up a bunch of manifests into a single config directory, run the following from within this repo:

$ go run . --kubeconfig $HOME/.kube/config --output=/path/to/output/dir /path/to/manifests/to/split/*

The tool will not recurse through the input directories to find manifests. To recursively match all YAML files within a directory, use a glob like so:

/path/to/manifests/to/split/**/*.yaml

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
package discovery implements a way to retrieve discovery information from Kubernetes to determine whether resources are namespace or cluster scoped.
package discovery implements a way to retrieve discovery information from Kubernetes to determine whether resources are namespace or cluster scoped.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL