garethr / kubernetes-json-schema

A set of JSON schemas for various Kubernetes versions, extracted from the OpenAPI definitions
Other
253 stars 61 forks source link

Add support for different api versions per resource per kubernetes version #6

Closed ghost closed 6 years ago

ghost commented 6 years ago

It looks like v1.9.3-standalone-strict/horizontalpodautoscaler.json only supports the autoscaling/v1 api version of HPAs but the api version autoscaling/v2beta1 also exists in k8s 1.9. We're using autoscaling/v2beta1 for our HPAs which include the property spec.metrics[], so our strict validations are failing.

Is this a known limitation of kubeval/kubernetes-json-schema, if so when can we expect a fix? Looking to get this tool into our CI/CD pipeline as soon as this is possible.

ghost commented 6 years ago

Duplicate of https://github.com/garethr/kubeval/issues/57

Will be fixed by https://github.com/garethr/openapi2jsonschema/pull/11, https://github.com/garethr/kubernetes-json-schema/pull/4, and https://github.com/garethr/kubeval/pull/63.