kubeval icon indicating copy to clipboard operation
kubeval copied to clipboard

Schema cache

Open jeroenrinzema opened this issue 3 years ago • 0 comments

Each time kubeval is executed are the k8s schemas downloaded from https://kubernetesjsonschema.dev. It would be great if the fetched schemas could be cached to disk.

The cache could be cleared using a new command: kubeval purge cache. The usage of the cache could be disabled by passing a flag: --no-cache.

cat manifest.yaml | kubeval --kubernetes-version 1.16.0 --no-cache

The cache could be stored inside the $HOME directory of the user or inside a specific location. kubeval should not fail when unable to write the cache to disk (a warning instead could be logged).

This would be very useful for me personally since I am using kubeval inside my git hooks to validate my project HELM charts.

jeroenrinzema avatar Mar 26 '21 13:03 jeroenrinzema