Determine namespaceability of resources from openapi schema

This commit is contained in:
Morten Torkildsen
2020-09-12 14:37:56 -07:00
parent 5c8c7a043a
commit d083c7f1d0
7 changed files with 68115 additions and 4825 deletions

View File

@@ -38,7 +38,7 @@ metadata:
spec:
replicas: 3 # {"$ref": "#/definitions/io.k8s.cli.setters.replicas"}
`
_, err := openapi.AddSchema([]byte(schema)) // add the schema definitions
err := openapi.AddSchema([]byte(schema)) // add the schema definitions
if err != nil {
panic(err)
}
@@ -103,7 +103,7 @@ spec:
image: nginx:1.7.9 # {"$ref": "#/definitions/io.k8s.cli.substitutions.image"}
`
_, err := openapi.AddSchema([]byte(schema)) // add the schema definitions
err := openapi.AddSchema([]byte(schema)) // add the schema definitions
if err != nil {
panic(err)
}