Description
What would you like to be added:
We should add presubmits that verify that:
- All examples in our docs are valid
- Our CRDs are valid
To get to 1), we'll need to transition to embedding YAML examples from files in docs instead of adding the YAML directly to the markdown, similar to Gateway API. A large portion of this can be copied verbatim from Gateway API with https://github.com/kubernetes-sigs/gateway-api/blob/36514bbcaba862aea7a630105a3c8859a766feec/hack/test-crds-validation.sh#L113-L142.
With that said, presubmits would run even faster if we could do this with https://github.com/kubernetes-sigs/kubectl-validate.
Why is this needed:
It's very easy for examples in our docs to get out of sync with our API unless we have some automation for this.