kubectl-neat — screenshot of github.com

kubectl-neat

I find kubectl output often too verbose; this tool makes it readable by cleaning up extraneous metadata, default values, and status information from Kubernetes YAML and JSON.

Visit github.com →

Questions & Answers

What is kubectl-neat?
kubectl-neat is a command-line tool and kubectl plugin designed to remove clutter from Kubernetes YAML and JSON output. It processes resource manifests to strip away redundant information, system-generated fields, and default values for improved readability.
Who is kubectl-neat for?
kubectl-neat is intended for Kubernetes users, administrators, and developers who regularly interact with Kubernetes resources. It is particularly useful for anyone needing to review, debug, or share concise configurations without system-added verbosity.
When should I use kubectl-neat?
You should use kubectl-neat when viewing Kubernetes resource outputs (e.g., from `kubectl get -o yaml`) that are excessively verbose due to system-added fields. It simplifies the output, making it easier to focus on the essential, user-defined configuration aspects.
How does kubectl-neat clean up Kubernetes manifests?
kubectl-neat cleans manifests by primarily looking for default values inserted by Kubernetes' object model and attributes from common mutating admission controllers. It uses Kubernetes' own code to identify and remove fields that match these default or system-generated values.
How can I install and use kubectl-neat?
kubectl-neat can be installed using `kubectl krew install neat` or by downloading the standalone binary. It operates either as `kubectl neat` when installed via krew or `kubectl-neat` as a standalone, accepting input from files, stdin, or as a wrapper for `kubectl get` commands.