Skip to content

CRDs + examples should be validated with presubmits #679

@robscott

Description

@robscott

What would you like to be added:
We should add presubmits that verify that:

  1. All examples in our docs are valid
  2. 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.

Metadata

Metadata

Assignees

Labels

help wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.triage/acceptedIndicates an issue or PR is ready to be actively worked on.

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions