Files
kubevela/pkg/controller/utils/testdata/definition/normalOpenAPISchema.json
Zheng Xi Zhou c2b6e6efdd Store capability OpenAPI V3 JSON schema in ConfigMap (#1106)
* Store capability OpenAPI V3 JSON schema in ConfigMap

Store the OpenAPI v3 JSON Schema generated from the parameters of
a capability which could be used by api server

To fix #899

address comments
try to fix data race issue

Co-authored-by: Jianbo Sun <wonderflow.sun@gmail.com>

* address comments: generate cue instance from cue json instead of local file

* update ConfigMap data at any time

* add more unit-test

* fix conflicts

* adapt to new spec.schematic.cue.template

* adapt to new spec.schematic.cue.template for controller unittest cases

* fix ci issues

* adapt to namespaced scope definition

* add more testcases on namespaced definitions with and without namespaces

Co-authored-by: Jianbo Sun <wonderflow.sun@gmail.com>
2021-03-10 10:44:58 +08:00

35 lines
1.4 KiB
JSON

{
"openapi": "3.0.0",
"info": {
"title": "Generated by cue.",
"version": "no version"
},
"paths": {},
"components": {
"schemas": {
"parameter": {
"type": "object",
"required": [
"image"
],
"properties": {
"cmd": {
"description": "+usage=Commands to run in the container",
"type": "array",
"items": {
"type": "string"
}
},
"image": {
"description": "+usage=Which image would you like to use for your service\n+short=i",
"type": "string"
},
"cpu": {
"type": "string"
}
}
}
}
}
}