Skip to content

Commit 7147916

Browse files
authored
Merge pull request #461 from DataDog/kube-patch-2
Update patch payload type
2 parents b4560fa + 9ebac35 commit 7147916

5 files changed

Lines changed: 168 additions & 114 deletions

File tree

kubeactions/jsonschema/KubeAction.json

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,25 @@
9999
],
100100
"properties": {
101101
"patch": {
102-
"type": "string",
103-
"description": "Patch is the raw JSON patch to apply to the deployment. Example: {\"spec\": {\"replicas\": 3}} to scale, or {\"spec\": {\"template\": {\"spec\": {\"containers\": [{\"name\": \"app\", \"image\": \"app:v2\"}]}}}} to update an image.",
104-
"format": "binary",
105-
"binaryEncoding": "base64"
102+
"oneOf": [
103+
{
104+
"type": "array"
105+
},
106+
{
107+
"type": "boolean"
108+
},
109+
{
110+
"type": "number"
111+
},
112+
{
113+
"type": "object"
114+
},
115+
{
116+
"type": "string"
117+
}
118+
],
119+
"title": "Value",
120+
"description": "`Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. The JSON representation for `Value` is JSON value."
106121
},
107122
"patch_strategy": {
108123
"type": "string",

kubeactions/jsonschema/KubeActionsList.json

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -117,10 +117,25 @@
117117
],
118118
"properties": {
119119
"patch": {
120-
"type": "string",
121-
"description": "Patch is the raw JSON patch to apply to the deployment. Example: {\"spec\": {\"replicas\": 3}} to scale, or {\"spec\": {\"template\": {\"spec\": {\"containers\": [{\"name\": \"app\", \"image\": \"app:v2\"}]}}}} to update an image.",
122-
"format": "binary",
123-
"binaryEncoding": "base64"
120+
"oneOf": [
121+
{
122+
"type": "array"
123+
},
124+
{
125+
"type": "boolean"
126+
},
127+
{
128+
"type": "number"
129+
},
130+
{
131+
"type": "object"
132+
},
133+
{
134+
"type": "string"
135+
}
136+
],
137+
"title": "Value",
138+
"description": "`Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. The JSON representation for `Value` is JSON value."
124139
},
125140
"patch_strategy": {
126141
"type": "string",

kubeactions/jsonschema/PatchDeploymentParams.json

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,25 @@
88
],
99
"properties": {
1010
"patch": {
11-
"type": "string",
12-
"description": "Patch is the raw JSON patch to apply to the deployment. Example: {\"spec\": {\"replicas\": 3}} to scale, or {\"spec\": {\"template\": {\"spec\": {\"containers\": [{\"name\": \"app\", \"image\": \"app:v2\"}]}}}} to update an image.",
13-
"format": "binary",
14-
"binaryEncoding": "base64"
11+
"oneOf": [
12+
{
13+
"type": "array"
14+
},
15+
{
16+
"type": "boolean"
17+
},
18+
{
19+
"type": "number"
20+
},
21+
{
22+
"type": "object"
23+
},
24+
{
25+
"type": "string"
26+
}
27+
],
28+
"title": "Value",
29+
"description": "`Value` represents a dynamically typed value which can be either null, a number, a string, a boolean, a recursive struct value, or a list of values. A producer of value is expected to set one of these variants. Absence of any variant indicates an error. The JSON representation for `Value` is JSON value."
1530
},
1631
"patch_strategy": {
1732
"type": "string",

0 commit comments

Comments
 (0)