File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,14 @@ import (
24
24
// KnownPackages overrides types in some comment packages that have custom validation
25
25
// but don't have validation markers on them (since they're from core Kubernetes).
26
26
var KnownPackages = map [string ]PackageOverride {
27
+ "k8s.io/api/core/v1" : func (p * Parser , pkg * loader.Package ) {
28
+ // Explicit defaulting for the corev1.Protocol type in lieu of https://github.com/kubernetes/enhancements/pull/1928
29
+ p .Schemata [TypeIdent {Name : "Protocol" , Package : pkg }] = apiext.JSONSchemaProps {
30
+ Type : "string" ,
31
+ Default : & apiext.JSON {Raw : []byte (`"TCP"` )},
32
+ }
33
+ p .AddPackage (pkg )
34
+ },
27
35
28
36
"k8s.io/apimachinery/pkg/apis/meta/v1" : func (p * Parser , pkg * loader.Package ) {
29
37
// ObjectMeta is managed by the Kubernetes API server, so no need to
You can’t perform that action at this time.
0 commit comments