airshipctl/krm-functions/kubeval-validator
Ruslan Aliev f7fca469de Add KRM function to validate site documents
Proposed KRM function can perform static validation of the site
documents based on Kubeval. It allows to specify additional CRD
locations to be able to validate custom resources. As input,
it uses document bundle created from desired phase's document
entry point or output from render command.

Change-Id: Ib76d88a6e6c7f3b29b29cab0abe038eef380686f
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Relates-To: #19
2021-04-22 11:13:40 -05:00
..
image Add KRM function to validate site documents 2021-04-22 11:13:40 -05:00
local-resource Add KRM function to validate site documents 2021-04-22 11:13:40 -05:00
Makefile Add KRM function to validate site documents 2021-04-22 11:13:40 -05:00
README.md Add KRM function to validate site documents 2021-04-22 11:13:40 -05:00

Validation

This is a KRM function which implementing a validation function against kubeval.

Function implementation

The function is implemented as an image, and built using make image.

Function configuration

A number of settings can be modified for kubeval in the struct Spec. See the Config struct definition in main.go for documentation.

Function invocation

The function by running validate command via airshipctl:

airshipctl phase validate <phase_name>

This exists non-zero if kubeval detects an invalid Resource.