instrumenta / instrumenta/kubeval
Alert when there is no schema available for an specific K8s version
- Dominant language
- Go
- Stars
- 3.2k
- Forks
- 227
- PR merge metrics
- No merged PRs in 30d
Description
Hello,
I was wondering if it will be a good idea of an enhancement to WARN or FAIL with error when executing kubeval with a kubernetes version where there are no schemas available.
Actually, for example launching this command:
`kubeval --ignore-missing-schemas -v 1.17.5 -d .\infrastructure\`
I want to pass `--ignore-missing-schemas` because of CRDs and other schemas which can be not found. But I will be able to not ignore missing base schemas of that kubernetes version.
Will provide an output with all YAML files as WARN because the schema is not found:
```
WARN - infrastructure\core\manifests\internal-load-balancer.yaml containing a Service (kube-system.internal-app) was not validated against a schema
WARN - infrastructure\core\manifests\rbac\cluster-admins.yaml containing a ClusterRoleBinding (cluster-admins) was not validated against a schema
WARN - infrastructure\core\manifests\rbac\cluster-readers.yaml containing a ClusterRoleBinding (cluster-readers) was not validated against a schema
```
It will be possible if a kubernetes version is not found, error with another message or try to validate against the nearest lower minor version? Do you think it will be a good enhancement?
Using kubeval version as follows:
```
kubeval --version
Version: 0.15.0
Commit: df50ea7fd4fd202458002a40a6a39ffbb3125bad
Date: 2020-04-14T09:32:29Z
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.