@scaleway/sdk-k8s 2.5.0 → 2.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/_virtual/_rolldown/runtime.js +11 -0
- package/dist/index.gen.js +2 -4
- package/dist/v1/api.gen.js +436 -615
- package/dist/v1/api.utils.js +9 -11
- package/dist/v1/content.gen.js +16 -17
- package/dist/v1/index.js +11 -9
- package/dist/v1/marshalling.gen.js +425 -591
- package/dist/v1/types.gen.d.ts +1 -1
- package/dist/v1/validation-rules.gen.js +97 -163
- package/package.json +4 -4
|
@@ -1,659 +1,493 @@
|
|
|
1
|
+
import { isJSONObject, resolveOneOf, unmarshalArrayOfObject, unmarshalDate } from "@scaleway/sdk-client";
|
|
1
2
|
import randomName from "@scaleway/random-name";
|
|
2
|
-
import { resolveOneOf, isJSONObject, unmarshalArrayOfObject, unmarshalDate } from "@scaleway/sdk-client";
|
|
3
3
|
const unmarshalVersion = (data) => {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
name: data.name,
|
|
19
|
-
region: data.region,
|
|
20
|
-
releasedAt: unmarshalDate(data.released_at)
|
|
21
|
-
};
|
|
4
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Version' failed as data isn't a dictionary.`);
|
|
5
|
+
return {
|
|
6
|
+
availableAdmissionPlugins: data.available_admission_plugins,
|
|
7
|
+
availableCnis: data.available_cnis,
|
|
8
|
+
availableContainerRuntimes: data.available_container_runtimes,
|
|
9
|
+
availableFeatureGates: data.available_feature_gates,
|
|
10
|
+
availableKubeletArgs: data.available_kubelet_args,
|
|
11
|
+
deprecatedAt: unmarshalDate(data.deprecated_at),
|
|
12
|
+
endOfLifeAt: unmarshalDate(data.end_of_life_at),
|
|
13
|
+
label: data.label,
|
|
14
|
+
name: data.name,
|
|
15
|
+
region: data.region,
|
|
16
|
+
releasedAt: unmarshalDate(data.released_at)
|
|
17
|
+
};
|
|
22
18
|
};
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
return {
|
|
30
|
-
day: data.day,
|
|
31
|
-
startHour: data.start_hour
|
|
32
|
-
};
|
|
19
|
+
var unmarshalMaintenanceWindow = (data) => {
|
|
20
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'MaintenanceWindow' failed as data isn't a dictionary.`);
|
|
21
|
+
return {
|
|
22
|
+
day: data.day,
|
|
23
|
+
startHour: data.start_hour
|
|
24
|
+
};
|
|
33
25
|
};
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
return {
|
|
41
|
-
enabled: data.enabled,
|
|
42
|
-
maintenanceWindow: data.maintenance_window ? unmarshalMaintenanceWindow(data.maintenance_window) : void 0
|
|
43
|
-
};
|
|
26
|
+
var unmarshalClusterAutoUpgrade = (data) => {
|
|
27
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ClusterAutoUpgrade' failed as data isn't a dictionary.`);
|
|
28
|
+
return {
|
|
29
|
+
enabled: data.enabled,
|
|
30
|
+
maintenanceWindow: data.maintenance_window ? unmarshalMaintenanceWindow(data.maintenance_window) : void 0
|
|
31
|
+
};
|
|
44
32
|
};
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
scaleDownDisabled: data.scale_down_disabled,
|
|
60
|
-
scaleDownUnneededTime: data.scale_down_unneeded_time,
|
|
61
|
-
scaleDownUtilizationThreshold: data.scale_down_utilization_threshold
|
|
62
|
-
};
|
|
33
|
+
var unmarshalClusterAutoscalerConfig = (data) => {
|
|
34
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ClusterAutoscalerConfig' failed as data isn't a dictionary.`);
|
|
35
|
+
return {
|
|
36
|
+
balanceSimilarNodeGroups: data.balance_similar_node_groups,
|
|
37
|
+
estimator: data.estimator,
|
|
38
|
+
expander: data.expander,
|
|
39
|
+
expendablePodsPriorityCutoff: data.expendable_pods_priority_cutoff,
|
|
40
|
+
ignoreDaemonsetsUtilization: data.ignore_daemonsets_utilization,
|
|
41
|
+
maxGracefulTerminationSec: data.max_graceful_termination_sec,
|
|
42
|
+
scaleDownDelayAfterAdd: data.scale_down_delay_after_add,
|
|
43
|
+
scaleDownDisabled: data.scale_down_disabled,
|
|
44
|
+
scaleDownUnneededTime: data.scale_down_unneeded_time,
|
|
45
|
+
scaleDownUtilizationThreshold: data.scale_down_utilization_threshold
|
|
46
|
+
};
|
|
63
47
|
};
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
requiredClaim: data.required_claim,
|
|
76
|
-
usernameClaim: data.username_claim,
|
|
77
|
-
usernamePrefix: data.username_prefix
|
|
78
|
-
};
|
|
48
|
+
var unmarshalClusterOpenIDConnectConfig = (data) => {
|
|
49
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ClusterOpenIDConnectConfig' failed as data isn't a dictionary.`);
|
|
50
|
+
return {
|
|
51
|
+
clientId: data.client_id,
|
|
52
|
+
groupsClaim: data.groups_claim,
|
|
53
|
+
groupsPrefix: data.groups_prefix,
|
|
54
|
+
issuerUrl: data.issuer_url,
|
|
55
|
+
requiredClaim: data.required_claim,
|
|
56
|
+
usernameClaim: data.username_claim,
|
|
57
|
+
usernamePrefix: data.username_prefix
|
|
58
|
+
};
|
|
79
59
|
};
|
|
80
60
|
const unmarshalCluster = (data) => {
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
updatedAt: unmarshalDate(data.updated_at),
|
|
114
|
-
upgradeAvailable: data.upgrade_available,
|
|
115
|
-
version: data.version
|
|
116
|
-
};
|
|
61
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Cluster' failed as data isn't a dictionary.`);
|
|
62
|
+
return {
|
|
63
|
+
aclAvailable: data.acl_available,
|
|
64
|
+
admissionPlugins: data.admission_plugins,
|
|
65
|
+
apiserverCertSans: data.apiserver_cert_sans,
|
|
66
|
+
autoUpgrade: data.auto_upgrade ? unmarshalClusterAutoUpgrade(data.auto_upgrade) : void 0,
|
|
67
|
+
autoscalerConfig: data.autoscaler_config ? unmarshalClusterAutoscalerConfig(data.autoscaler_config) : void 0,
|
|
68
|
+
clusterUrl: data.cluster_url,
|
|
69
|
+
cni: data.cni,
|
|
70
|
+
commitmentEndsAt: unmarshalDate(data.commitment_ends_at),
|
|
71
|
+
createdAt: unmarshalDate(data.created_at),
|
|
72
|
+
description: data.description,
|
|
73
|
+
dnsWildcard: data.dns_wildcard,
|
|
74
|
+
featureGates: data.feature_gates,
|
|
75
|
+
iamNodesGroupId: data.iam_nodes_group_id,
|
|
76
|
+
id: data.id,
|
|
77
|
+
name: data.name,
|
|
78
|
+
openIdConnectConfig: data.open_id_connect_config ? unmarshalClusterOpenIDConnectConfig(data.open_id_connect_config) : void 0,
|
|
79
|
+
organizationId: data.organization_id,
|
|
80
|
+
podCidr: data.pod_cidr,
|
|
81
|
+
privateNetworkId: data.private_network_id,
|
|
82
|
+
projectId: data.project_id,
|
|
83
|
+
region: data.region,
|
|
84
|
+
serviceCidr: data.service_cidr,
|
|
85
|
+
serviceDnsIp: data.service_dns_ip,
|
|
86
|
+
status: data.status,
|
|
87
|
+
tags: data.tags,
|
|
88
|
+
type: data.type,
|
|
89
|
+
updatedAt: unmarshalDate(data.updated_at),
|
|
90
|
+
upgradeAvailable: data.upgrade_available,
|
|
91
|
+
version: data.version
|
|
92
|
+
};
|
|
117
93
|
};
|
|
118
94
|
const unmarshalNode = (data) => {
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
region: data.region,
|
|
136
|
-
status: data.status,
|
|
137
|
-
updatedAt: unmarshalDate(data.updated_at)
|
|
138
|
-
};
|
|
95
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Node' failed as data isn't a dictionary.`);
|
|
96
|
+
return {
|
|
97
|
+
clusterId: data.cluster_id,
|
|
98
|
+
conditions: data.conditions,
|
|
99
|
+
createdAt: unmarshalDate(data.created_at),
|
|
100
|
+
errorMessage: data.error_message,
|
|
101
|
+
id: data.id,
|
|
102
|
+
name: data.name,
|
|
103
|
+
poolId: data.pool_id,
|
|
104
|
+
providerId: data.provider_id,
|
|
105
|
+
publicIpV4: data.public_ip_v4,
|
|
106
|
+
publicIpV6: data.public_ip_v6,
|
|
107
|
+
region: data.region,
|
|
108
|
+
status: data.status,
|
|
109
|
+
updatedAt: unmarshalDate(data.updated_at)
|
|
110
|
+
};
|
|
139
111
|
};
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
effect: data.effect,
|
|
148
|
-
key: data.key,
|
|
149
|
-
value: data.value
|
|
150
|
-
};
|
|
112
|
+
var unmarshalCoreV1Taint = (data) => {
|
|
113
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'CoreV1Taint' failed as data isn't a dictionary.`);
|
|
114
|
+
return {
|
|
115
|
+
effect: data.effect,
|
|
116
|
+
key: data.key,
|
|
117
|
+
value: data.value
|
|
118
|
+
};
|
|
151
119
|
};
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
return {
|
|
159
|
-
maxSurge: data.max_surge,
|
|
160
|
-
maxUnavailable: data.max_unavailable
|
|
161
|
-
};
|
|
120
|
+
var unmarshalPoolUpgradePolicy = (data) => {
|
|
121
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'PoolUpgradePolicy' failed as data isn't a dictionary.`);
|
|
122
|
+
return {
|
|
123
|
+
maxSurge: data.max_surge,
|
|
124
|
+
maxUnavailable: data.max_unavailable
|
|
125
|
+
};
|
|
162
126
|
};
|
|
163
127
|
const unmarshalPool = (data) => {
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
upgradePolicy: data.upgrade_policy ? unmarshalPoolUpgradePolicy(data.upgrade_policy) : void 0,
|
|
195
|
-
version: data.version,
|
|
196
|
-
zone: data.zone
|
|
197
|
-
};
|
|
128
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Pool' failed as data isn't a dictionary.`);
|
|
129
|
+
return {
|
|
130
|
+
autohealing: data.autohealing,
|
|
131
|
+
autoscaling: data.autoscaling,
|
|
132
|
+
clusterId: data.cluster_id,
|
|
133
|
+
containerRuntime: data.container_runtime,
|
|
134
|
+
createdAt: unmarshalDate(data.created_at),
|
|
135
|
+
id: data.id,
|
|
136
|
+
kubeletArgs: data.kubelet_args,
|
|
137
|
+
labels: data.labels,
|
|
138
|
+
maxSize: data.max_size,
|
|
139
|
+
minSize: data.min_size,
|
|
140
|
+
name: data.name,
|
|
141
|
+
nodeType: data.node_type,
|
|
142
|
+
placementGroupId: data.placement_group_id,
|
|
143
|
+
publicIpDisabled: data.public_ip_disabled,
|
|
144
|
+
region: data.region,
|
|
145
|
+
rootVolumeSize: data.root_volume_size,
|
|
146
|
+
rootVolumeType: data.root_volume_type,
|
|
147
|
+
securityGroupId: data.security_group_id,
|
|
148
|
+
size: data.size,
|
|
149
|
+
startupTaints: unmarshalArrayOfObject(data.startup_taints, unmarshalCoreV1Taint),
|
|
150
|
+
status: data.status,
|
|
151
|
+
tags: data.tags,
|
|
152
|
+
taints: unmarshalArrayOfObject(data.taints, unmarshalCoreV1Taint),
|
|
153
|
+
updatedAt: unmarshalDate(data.updated_at),
|
|
154
|
+
upgradePolicy: data.upgrade_policy ? unmarshalPoolUpgradePolicy(data.upgrade_policy) : void 0,
|
|
155
|
+
version: data.version,
|
|
156
|
+
zone: data.zone
|
|
157
|
+
};
|
|
198
158
|
};
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
id: data.id,
|
|
208
|
-
ip: data.ip,
|
|
209
|
-
scalewayRanges: data.scaleway_ranges
|
|
210
|
-
};
|
|
159
|
+
var unmarshalACLRule = (data) => {
|
|
160
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ACLRule' failed as data isn't a dictionary.`);
|
|
161
|
+
return {
|
|
162
|
+
description: data.description,
|
|
163
|
+
id: data.id,
|
|
164
|
+
ip: data.ip,
|
|
165
|
+
scalewayRanges: data.scaleway_ranges
|
|
166
|
+
};
|
|
211
167
|
};
|
|
212
168
|
const unmarshalAddClusterACLRulesResponse = (data) => {
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
`Unmarshalling the type 'AddClusterACLRulesResponse' failed as data isn't a dictionary.`
|
|
216
|
-
);
|
|
217
|
-
}
|
|
218
|
-
return {
|
|
219
|
-
rules: unmarshalArrayOfObject(data.rules, unmarshalACLRule)
|
|
220
|
-
};
|
|
169
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'AddClusterACLRulesResponse' failed as data isn't a dictionary.`);
|
|
170
|
+
return { rules: unmarshalArrayOfObject(data.rules, unmarshalACLRule) };
|
|
221
171
|
};
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
effect: data.effect,
|
|
230
|
-
key: data.key,
|
|
231
|
-
value: data.value
|
|
232
|
-
};
|
|
172
|
+
var unmarshalExternalNodeCoreV1Taint = (data) => {
|
|
173
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ExternalNodeCoreV1Taint' failed as data isn't a dictionary.`);
|
|
174
|
+
return {
|
|
175
|
+
effect: data.effect,
|
|
176
|
+
key: data.key,
|
|
177
|
+
value: data.value
|
|
178
|
+
};
|
|
233
179
|
};
|
|
234
180
|
const unmarshalExternalNode = (data) => {
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
nodeTaints: unmarshalArrayOfObject(data.node_taints, unmarshalExternalNodeCoreV1Taint),
|
|
253
|
-
poolVersion: data.pool_version,
|
|
254
|
-
runcVersion: data.runc_version
|
|
255
|
-
};
|
|
181
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ExternalNode' failed as data isn't a dictionary.`);
|
|
182
|
+
return {
|
|
183
|
+
clusterCa: data.cluster_ca,
|
|
184
|
+
clusterUrl: data.cluster_url,
|
|
185
|
+
cniPluginsVersion: data.cni_plugins_version,
|
|
186
|
+
containerdVersion: data.containerd_version,
|
|
187
|
+
externalIp: data.external_ip,
|
|
188
|
+
iamToken: data.iam_token,
|
|
189
|
+
id: data.id,
|
|
190
|
+
kubeToken: data.kube_token,
|
|
191
|
+
kubeletConfig: data.kubelet_config,
|
|
192
|
+
name: data.name,
|
|
193
|
+
nodeLabels: data.node_labels,
|
|
194
|
+
nodeTaints: unmarshalArrayOfObject(data.node_taints, unmarshalExternalNodeCoreV1Taint),
|
|
195
|
+
poolVersion: data.pool_version,
|
|
196
|
+
runcVersion: data.runc_version
|
|
197
|
+
};
|
|
256
198
|
};
|
|
257
199
|
const unmarshalExternalNodeAuth = (data) => {
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
return {
|
|
264
|
-
metadataUrl: data.metadata_url,
|
|
265
|
-
nodeSecretKey: data.node_secret_key
|
|
266
|
-
};
|
|
200
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ExternalNodeAuth' failed as data isn't a dictionary.`);
|
|
201
|
+
return {
|
|
202
|
+
metadataUrl: data.metadata_url,
|
|
203
|
+
nodeSecretKey: data.node_secret_key
|
|
204
|
+
};
|
|
267
205
|
};
|
|
268
206
|
const unmarshalListClusterACLRulesResponse = (data) => {
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
return {
|
|
275
|
-
rules: unmarshalArrayOfObject(data.rules, unmarshalACLRule),
|
|
276
|
-
totalCount: data.total_count
|
|
277
|
-
};
|
|
207
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListClusterACLRulesResponse' failed as data isn't a dictionary.`);
|
|
208
|
+
return {
|
|
209
|
+
rules: unmarshalArrayOfObject(data.rules, unmarshalACLRule),
|
|
210
|
+
totalCount: data.total_count
|
|
211
|
+
};
|
|
278
212
|
};
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
name: data.name,
|
|
294
|
-
resiliency: data.resiliency,
|
|
295
|
-
sla: data.sla
|
|
296
|
-
};
|
|
213
|
+
var unmarshalClusterType = (data) => {
|
|
214
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ClusterType' failed as data isn't a dictionary.`);
|
|
215
|
+
return {
|
|
216
|
+
auditLogsSupported: data.audit_logs_supported,
|
|
217
|
+
availability: data.availability,
|
|
218
|
+
commitmentDelay: data.commitment_delay,
|
|
219
|
+
dedicated: data.dedicated,
|
|
220
|
+
maxEtcdSize: data.max_etcd_size,
|
|
221
|
+
maxNodes: data.max_nodes,
|
|
222
|
+
memory: data.memory,
|
|
223
|
+
name: data.name,
|
|
224
|
+
resiliency: data.resiliency,
|
|
225
|
+
sla: data.sla
|
|
226
|
+
};
|
|
297
227
|
};
|
|
298
228
|
const unmarshalListClusterAvailableTypesResponse = (data) => {
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
return {
|
|
305
|
-
clusterTypes: unmarshalArrayOfObject(data.cluster_types, unmarshalClusterType),
|
|
306
|
-
totalCount: data.total_count
|
|
307
|
-
};
|
|
229
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListClusterAvailableTypesResponse' failed as data isn't a dictionary.`);
|
|
230
|
+
return {
|
|
231
|
+
clusterTypes: unmarshalArrayOfObject(data.cluster_types, unmarshalClusterType),
|
|
232
|
+
totalCount: data.total_count
|
|
233
|
+
};
|
|
308
234
|
};
|
|
309
235
|
const unmarshalListClusterAvailableVersionsResponse = (data) => {
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
`Unmarshalling the type 'ListClusterAvailableVersionsResponse' failed as data isn't a dictionary.`
|
|
313
|
-
);
|
|
314
|
-
}
|
|
315
|
-
return {
|
|
316
|
-
versions: unmarshalArrayOfObject(data.versions, unmarshalVersion)
|
|
317
|
-
};
|
|
236
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListClusterAvailableVersionsResponse' failed as data isn't a dictionary.`);
|
|
237
|
+
return { versions: unmarshalArrayOfObject(data.versions, unmarshalVersion) };
|
|
318
238
|
};
|
|
319
239
|
const unmarshalListClusterTypesResponse = (data) => {
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
return {
|
|
326
|
-
clusterTypes: unmarshalArrayOfObject(data.cluster_types, unmarshalClusterType),
|
|
327
|
-
totalCount: data.total_count
|
|
328
|
-
};
|
|
240
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListClusterTypesResponse' failed as data isn't a dictionary.`);
|
|
241
|
+
return {
|
|
242
|
+
clusterTypes: unmarshalArrayOfObject(data.cluster_types, unmarshalClusterType),
|
|
243
|
+
totalCount: data.total_count
|
|
244
|
+
};
|
|
329
245
|
};
|
|
330
246
|
const unmarshalListClustersResponse = (data) => {
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
return {
|
|
337
|
-
clusters: unmarshalArrayOfObject(data.clusters, unmarshalCluster),
|
|
338
|
-
totalCount: data.total_count
|
|
339
|
-
};
|
|
247
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListClustersResponse' failed as data isn't a dictionary.`);
|
|
248
|
+
return {
|
|
249
|
+
clusters: unmarshalArrayOfObject(data.clusters, unmarshalCluster),
|
|
250
|
+
totalCount: data.total_count
|
|
251
|
+
};
|
|
340
252
|
};
|
|
341
253
|
const unmarshalListNodesResponse = (data) => {
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
return {
|
|
348
|
-
nodes: unmarshalArrayOfObject(data.nodes, unmarshalNode),
|
|
349
|
-
totalCount: data.total_count
|
|
350
|
-
};
|
|
254
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListNodesResponse' failed as data isn't a dictionary.`);
|
|
255
|
+
return {
|
|
256
|
+
nodes: unmarshalArrayOfObject(data.nodes, unmarshalNode),
|
|
257
|
+
totalCount: data.total_count
|
|
258
|
+
};
|
|
351
259
|
};
|
|
352
260
|
const unmarshalListPoolsResponse = (data) => {
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
return {
|
|
359
|
-
pools: unmarshalArrayOfObject(data.pools, unmarshalPool),
|
|
360
|
-
totalCount: data.total_count
|
|
361
|
-
};
|
|
261
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListPoolsResponse' failed as data isn't a dictionary.`);
|
|
262
|
+
return {
|
|
263
|
+
pools: unmarshalArrayOfObject(data.pools, unmarshalPool),
|
|
264
|
+
totalCount: data.total_count
|
|
265
|
+
};
|
|
362
266
|
};
|
|
363
267
|
const unmarshalListVersionsResponse = (data) => {
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
`Unmarshalling the type 'ListVersionsResponse' failed as data isn't a dictionary.`
|
|
367
|
-
);
|
|
368
|
-
}
|
|
369
|
-
return {
|
|
370
|
-
versions: unmarshalArrayOfObject(data.versions, unmarshalVersion)
|
|
371
|
-
};
|
|
268
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListVersionsResponse' failed as data isn't a dictionary.`);
|
|
269
|
+
return { versions: unmarshalArrayOfObject(data.versions, unmarshalVersion) };
|
|
372
270
|
};
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
effect: data.effect,
|
|
381
|
-
key: data.key,
|
|
382
|
-
value: data.value
|
|
383
|
-
};
|
|
271
|
+
var unmarshalNodeMetadataCoreV1Taint = (data) => {
|
|
272
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'NodeMetadataCoreV1Taint' failed as data isn't a dictionary.`);
|
|
273
|
+
return {
|
|
274
|
+
effect: data.effect,
|
|
275
|
+
key: data.key,
|
|
276
|
+
value: data.value
|
|
277
|
+
};
|
|
384
278
|
};
|
|
385
279
|
const unmarshalNodeMetadata = (data) => {
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
updaterBinPath: data.updater_bin_path,
|
|
409
|
-
updaterBinUrl: data.updater_bin_url,
|
|
410
|
-
updaterBinVersion: data.updater_bin_version
|
|
411
|
-
};
|
|
280
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'NodeMetadata' failed as data isn't a dictionary.`);
|
|
281
|
+
return {
|
|
282
|
+
clusterCa: data.cluster_ca,
|
|
283
|
+
clusterUrl: data.cluster_url,
|
|
284
|
+
credentialProviderConfig: data.credential_provider_config,
|
|
285
|
+
externalIp: data.external_ip,
|
|
286
|
+
hasGpu: data.has_gpu,
|
|
287
|
+
id: data.id,
|
|
288
|
+
installerTags: data.installer_tags,
|
|
289
|
+
kubeletConfig: data.kubelet_config,
|
|
290
|
+
name: data.name,
|
|
291
|
+
nodeLabels: data.node_labels,
|
|
292
|
+
nodeTaints: unmarshalArrayOfObject(data.node_taints, unmarshalNodeMetadataCoreV1Taint),
|
|
293
|
+
poolVersion: data.pool_version,
|
|
294
|
+
providerId: data.provider_id,
|
|
295
|
+
repoUri: data.repo_uri,
|
|
296
|
+
resolvconfPath: data.resolvconf_path,
|
|
297
|
+
templateArgs: data.template_args,
|
|
298
|
+
updaterBinPath: data.updater_bin_path,
|
|
299
|
+
updaterBinUrl: data.updater_bin_url,
|
|
300
|
+
updaterBinVersion: data.updater_bin_version
|
|
301
|
+
};
|
|
412
302
|
};
|
|
413
303
|
const unmarshalSetClusterACLRulesResponse = (data) => {
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
`Unmarshalling the type 'SetClusterACLRulesResponse' failed as data isn't a dictionary.`
|
|
417
|
-
);
|
|
418
|
-
}
|
|
419
|
-
return {
|
|
420
|
-
rules: unmarshalArrayOfObject(data.rules, unmarshalACLRule)
|
|
421
|
-
};
|
|
304
|
+
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'SetClusterACLRulesResponse' failed as data isn't a dictionary.`);
|
|
305
|
+
return { rules: unmarshalArrayOfObject(data.rules, unmarshalACLRule) };
|
|
422
306
|
};
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
value: request.scalewayRanges
|
|
433
|
-
}
|
|
434
|
-
])
|
|
307
|
+
var marshalACLRuleRequest = (request, defaults) => ({
|
|
308
|
+
description: request.description,
|
|
309
|
+
...resolveOneOf([{
|
|
310
|
+
param: "ip",
|
|
311
|
+
value: request.ip
|
|
312
|
+
}, {
|
|
313
|
+
param: "scaleway_ranges",
|
|
314
|
+
value: request.scalewayRanges
|
|
315
|
+
}])
|
|
435
316
|
});
|
|
436
|
-
const marshalAddClusterACLRulesRequest = (request, defaults) => ({
|
|
437
|
-
|
|
317
|
+
const marshalAddClusterACLRulesRequest = (request, defaults) => ({ acls: request.acls !== void 0 ? request.acls.map((elt) => marshalACLRuleRequest(elt, defaults)) : void 0 });
|
|
318
|
+
var marshalMaintenanceWindow = (request, defaults) => ({
|
|
319
|
+
day: request.day,
|
|
320
|
+
start_hour: request.startHour
|
|
438
321
|
});
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
322
|
+
var marshalCoreV1Taint = (request, defaults) => ({
|
|
323
|
+
effect: request.effect,
|
|
324
|
+
key: request.key,
|
|
325
|
+
value: request.value
|
|
442
326
|
});
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
value: request.value
|
|
327
|
+
var marshalCreateClusterRequestPoolConfigUpgradePolicy = (request, defaults) => ({
|
|
328
|
+
max_surge: request.maxSurge,
|
|
329
|
+
max_unavailable: request.maxUnavailable
|
|
447
330
|
});
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
331
|
+
var marshalCreateClusterRequestAutoUpgrade = (request, defaults) => ({
|
|
332
|
+
enable: request.enable,
|
|
333
|
+
maintenance_window: request.maintenanceWindow !== void 0 ? marshalMaintenanceWindow(request.maintenanceWindow, defaults) : void 0
|
|
451
334
|
});
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
335
|
+
var marshalCreateClusterRequestAutoscalerConfig = (request, defaults) => ({
|
|
336
|
+
balance_similar_node_groups: request.balanceSimilarNodeGroups,
|
|
337
|
+
estimator: request.estimator,
|
|
338
|
+
expander: request.expander,
|
|
339
|
+
expendable_pods_priority_cutoff: request.expendablePodsPriorityCutoff,
|
|
340
|
+
ignore_daemonsets_utilization: request.ignoreDaemonsetsUtilization,
|
|
341
|
+
max_graceful_termination_sec: request.maxGracefulTerminationSec,
|
|
342
|
+
scale_down_delay_after_add: request.scaleDownDelayAfterAdd,
|
|
343
|
+
scale_down_disabled: request.scaleDownDisabled,
|
|
344
|
+
scale_down_unneeded_time: request.scaleDownUnneededTime,
|
|
345
|
+
scale_down_utilization_threshold: request.scaleDownUtilizationThreshold
|
|
455
346
|
});
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
scale_down_disabled: request.scaleDownDisabled,
|
|
465
|
-
scale_down_unneeded_time: request.scaleDownUnneededTime,
|
|
466
|
-
scale_down_utilization_threshold: request.scaleDownUtilizationThreshold
|
|
347
|
+
var marshalCreateClusterRequestOpenIDConnectConfig = (request, defaults) => ({
|
|
348
|
+
client_id: request.clientId,
|
|
349
|
+
groups_claim: request.groupsClaim,
|
|
350
|
+
groups_prefix: request.groupsPrefix,
|
|
351
|
+
issuer_url: request.issuerUrl,
|
|
352
|
+
required_claim: request.requiredClaim,
|
|
353
|
+
username_claim: request.usernameClaim,
|
|
354
|
+
username_prefix: request.usernamePrefix
|
|
467
355
|
});
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
root_volume_size: request.rootVolumeSize,
|
|
490
|
-
root_volume_type: request.rootVolumeType,
|
|
491
|
-
security_group_id: request.securityGroupId,
|
|
492
|
-
size: request.size,
|
|
493
|
-
startup_taints: request.startupTaints.map((elt) => marshalCoreV1Taint(elt)),
|
|
494
|
-
tags: request.tags,
|
|
495
|
-
taints: request.taints.map((elt) => marshalCoreV1Taint(elt)),
|
|
496
|
-
upgrade_policy: request.upgradePolicy !== void 0 ? marshalCreateClusterRequestPoolConfigUpgradePolicy(request.upgradePolicy) : void 0,
|
|
497
|
-
zone: request.zone
|
|
356
|
+
var marshalCreateClusterRequestPoolConfig = (request, defaults) => ({
|
|
357
|
+
autohealing: request.autohealing,
|
|
358
|
+
autoscaling: request.autoscaling,
|
|
359
|
+
container_runtime: request.containerRuntime,
|
|
360
|
+
kubelet_args: request.kubeletArgs,
|
|
361
|
+
labels: request.labels,
|
|
362
|
+
max_size: request.maxSize,
|
|
363
|
+
min_size: request.minSize,
|
|
364
|
+
name: request.name,
|
|
365
|
+
node_type: request.nodeType,
|
|
366
|
+
placement_group_id: request.placementGroupId,
|
|
367
|
+
public_ip_disabled: request.publicIpDisabled,
|
|
368
|
+
root_volume_size: request.rootVolumeSize,
|
|
369
|
+
root_volume_type: request.rootVolumeType,
|
|
370
|
+
security_group_id: request.securityGroupId,
|
|
371
|
+
size: request.size,
|
|
372
|
+
startup_taints: request.startupTaints.map((elt) => marshalCoreV1Taint(elt, defaults)),
|
|
373
|
+
tags: request.tags,
|
|
374
|
+
taints: request.taints.map((elt) => marshalCoreV1Taint(elt, defaults)),
|
|
375
|
+
upgrade_policy: request.upgradePolicy !== void 0 ? marshalCreateClusterRequestPoolConfigUpgradePolicy(request.upgradePolicy, defaults) : void 0,
|
|
376
|
+
zone: request.zone
|
|
498
377
|
});
|
|
499
378
|
const marshalCreateClusterRequest = (request, defaults) => ({
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
value: request.organizationId
|
|
527
|
-
}
|
|
528
|
-
])
|
|
379
|
+
admission_plugins: request.admissionPlugins,
|
|
380
|
+
apiserver_cert_sans: request.apiserverCertSans,
|
|
381
|
+
auto_upgrade: request.autoUpgrade !== void 0 ? marshalCreateClusterRequestAutoUpgrade(request.autoUpgrade, defaults) : void 0,
|
|
382
|
+
autoscaler_config: request.autoscalerConfig !== void 0 ? marshalCreateClusterRequestAutoscalerConfig(request.autoscalerConfig, defaults) : void 0,
|
|
383
|
+
cni: request.cni,
|
|
384
|
+
description: request.description,
|
|
385
|
+
feature_gates: request.featureGates,
|
|
386
|
+
name: request.name || randomName("k8s"),
|
|
387
|
+
open_id_connect_config: request.openIdConnectConfig !== void 0 ? marshalCreateClusterRequestOpenIDConnectConfig(request.openIdConnectConfig, defaults) : void 0,
|
|
388
|
+
pod_cidr: request.podCidr,
|
|
389
|
+
pools: request.pools !== void 0 ? request.pools.map((elt) => marshalCreateClusterRequestPoolConfig(elt, defaults)) : void 0,
|
|
390
|
+
private_network_id: request.privateNetworkId,
|
|
391
|
+
service_cidr: request.serviceCidr,
|
|
392
|
+
service_dns_ip: request.serviceDnsIp,
|
|
393
|
+
tags: request.tags,
|
|
394
|
+
type: request.type,
|
|
395
|
+
version: request.version,
|
|
396
|
+
...resolveOneOf([{
|
|
397
|
+
default: defaults.defaultProjectId,
|
|
398
|
+
param: "project_id",
|
|
399
|
+
value: request.projectId
|
|
400
|
+
}, {
|
|
401
|
+
default: defaults.defaultOrganizationId,
|
|
402
|
+
param: "organization_id",
|
|
403
|
+
value: request.organizationId
|
|
404
|
+
}])
|
|
529
405
|
});
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
406
|
+
var marshalCreatePoolRequestUpgradePolicy = (request, defaults) => ({
|
|
407
|
+
max_surge: request.maxSurge,
|
|
408
|
+
max_unavailable: request.maxUnavailable
|
|
533
409
|
});
|
|
534
410
|
const marshalCreatePoolRequest = (request, defaults) => ({
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
});
|
|
556
|
-
const marshalSetClusterACLRulesRequest = (request, defaults) => ({
|
|
557
|
-
acls: request.acls !== void 0 ? request.acls.map((elt) => marshalACLRuleRequest(elt)) : void 0
|
|
558
|
-
});
|
|
559
|
-
const marshalSetClusterTypeRequest = (request, defaults) => ({
|
|
560
|
-
type: request.type
|
|
561
|
-
});
|
|
562
|
-
const marshalSetPoolLabelsRequest = (request, defaults) => ({
|
|
563
|
-
labels: request.labels !== void 0 ? request.labels : void 0
|
|
411
|
+
autohealing: request.autohealing,
|
|
412
|
+
autoscaling: request.autoscaling,
|
|
413
|
+
container_runtime: request.containerRuntime,
|
|
414
|
+
kubelet_args: request.kubeletArgs !== void 0 ? request.kubeletArgs : void 0,
|
|
415
|
+
labels: request.labels !== void 0 ? request.labels : void 0,
|
|
416
|
+
max_size: request.maxSize,
|
|
417
|
+
min_size: request.minSize,
|
|
418
|
+
name: request.name || randomName("pool"),
|
|
419
|
+
node_type: request.nodeType,
|
|
420
|
+
placement_group_id: request.placementGroupId,
|
|
421
|
+
public_ip_disabled: request.publicIpDisabled,
|
|
422
|
+
root_volume_size: request.rootVolumeSize,
|
|
423
|
+
root_volume_type: request.rootVolumeType,
|
|
424
|
+
security_group_id: request.securityGroupId,
|
|
425
|
+
size: request.size,
|
|
426
|
+
startup_taints: request.startupTaints !== void 0 ? request.startupTaints.map((elt) => marshalCoreV1Taint(elt, defaults)) : void 0,
|
|
427
|
+
tags: request.tags,
|
|
428
|
+
taints: request.taints !== void 0 ? request.taints.map((elt) => marshalCoreV1Taint(elt, defaults)) : void 0,
|
|
429
|
+
upgrade_policy: request.upgradePolicy !== void 0 ? marshalCreatePoolRequestUpgradePolicy(request.upgradePolicy, defaults) : void 0,
|
|
430
|
+
zone: request.zone ?? defaults.defaultZone
|
|
564
431
|
});
|
|
565
|
-
const
|
|
566
|
-
|
|
432
|
+
const marshalSetClusterACLRulesRequest = (request, defaults) => ({ acls: request.acls !== void 0 ? request.acls.map((elt) => marshalACLRuleRequest(elt, defaults)) : void 0 });
|
|
433
|
+
const marshalSetClusterTypeRequest = (request, defaults) => ({ type: request.type });
|
|
434
|
+
const marshalSetPoolLabelsRequest = (request, defaults) => ({ labels: request.labels !== void 0 ? request.labels : void 0 });
|
|
435
|
+
const marshalSetPoolStartupTaintsRequest = (request, defaults) => ({ startup_taints: request.startupTaints !== void 0 ? request.startupTaints.map((elt) => marshalCoreV1Taint(elt, defaults)) : void 0 });
|
|
436
|
+
const marshalSetPoolTaintsRequest = (request, defaults) => ({ taints: request.taints !== void 0 ? request.taints.map((elt) => marshalCoreV1Taint(elt, defaults)) : void 0 });
|
|
437
|
+
var marshalUpdateClusterRequestAutoUpgrade = (request, defaults) => ({
|
|
438
|
+
enable: request.enable,
|
|
439
|
+
maintenance_window: request.maintenanceWindow !== void 0 ? marshalMaintenanceWindow(request.maintenanceWindow, defaults) : void 0
|
|
567
440
|
});
|
|
568
|
-
|
|
569
|
-
|
|
441
|
+
var marshalUpdateClusterRequestAutoscalerConfig = (request, defaults) => ({
|
|
442
|
+
balance_similar_node_groups: request.balanceSimilarNodeGroups,
|
|
443
|
+
estimator: request.estimator,
|
|
444
|
+
expander: request.expander,
|
|
445
|
+
expendable_pods_priority_cutoff: request.expendablePodsPriorityCutoff,
|
|
446
|
+
ignore_daemonsets_utilization: request.ignoreDaemonsetsUtilization,
|
|
447
|
+
max_graceful_termination_sec: request.maxGracefulTerminationSec,
|
|
448
|
+
scale_down_delay_after_add: request.scaleDownDelayAfterAdd,
|
|
449
|
+
scale_down_disabled: request.scaleDownDisabled,
|
|
450
|
+
scale_down_unneeded_time: request.scaleDownUnneededTime,
|
|
451
|
+
scale_down_utilization_threshold: request.scaleDownUtilizationThreshold
|
|
570
452
|
});
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
expendable_pods_priority_cutoff: request.expendablePodsPriorityCutoff,
|
|
580
|
-
ignore_daemonsets_utilization: request.ignoreDaemonsetsUtilization,
|
|
581
|
-
max_graceful_termination_sec: request.maxGracefulTerminationSec,
|
|
582
|
-
scale_down_delay_after_add: request.scaleDownDelayAfterAdd,
|
|
583
|
-
scale_down_disabled: request.scaleDownDisabled,
|
|
584
|
-
scale_down_unneeded_time: request.scaleDownUnneededTime,
|
|
585
|
-
scale_down_utilization_threshold: request.scaleDownUtilizationThreshold
|
|
586
|
-
});
|
|
587
|
-
const marshalUpdateClusterRequestOpenIDConnectConfig = (request, defaults) => ({
|
|
588
|
-
client_id: request.clientId,
|
|
589
|
-
groups_claim: request.groupsClaim,
|
|
590
|
-
groups_prefix: request.groupsPrefix,
|
|
591
|
-
issuer_url: request.issuerUrl,
|
|
592
|
-
required_claim: request.requiredClaim,
|
|
593
|
-
username_claim: request.usernameClaim,
|
|
594
|
-
username_prefix: request.usernamePrefix
|
|
453
|
+
var marshalUpdateClusterRequestOpenIDConnectConfig = (request, defaults) => ({
|
|
454
|
+
client_id: request.clientId,
|
|
455
|
+
groups_claim: request.groupsClaim,
|
|
456
|
+
groups_prefix: request.groupsPrefix,
|
|
457
|
+
issuer_url: request.issuerUrl,
|
|
458
|
+
required_claim: request.requiredClaim,
|
|
459
|
+
username_claim: request.usernameClaim,
|
|
460
|
+
username_prefix: request.usernamePrefix
|
|
595
461
|
});
|
|
596
462
|
const marshalUpdateClusterRequest = (request, defaults) => ({
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
463
|
+
admission_plugins: request.admissionPlugins,
|
|
464
|
+
apiserver_cert_sans: request.apiserverCertSans,
|
|
465
|
+
auto_upgrade: request.autoUpgrade !== void 0 ? marshalUpdateClusterRequestAutoUpgrade(request.autoUpgrade, defaults) : void 0,
|
|
466
|
+
autoscaler_config: request.autoscalerConfig !== void 0 ? marshalUpdateClusterRequestAutoscalerConfig(request.autoscalerConfig, defaults) : void 0,
|
|
467
|
+
description: request.description,
|
|
468
|
+
feature_gates: request.featureGates,
|
|
469
|
+
name: request.name,
|
|
470
|
+
open_id_connect_config: request.openIdConnectConfig !== void 0 ? marshalUpdateClusterRequestOpenIDConnectConfig(request.openIdConnectConfig, defaults) : void 0,
|
|
471
|
+
tags: request.tags
|
|
606
472
|
});
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
473
|
+
var marshalUpdatePoolRequestUpgradePolicy = (request, defaults) => ({
|
|
474
|
+
max_surge: request.maxSurge,
|
|
475
|
+
max_unavailable: request.maxUnavailable
|
|
610
476
|
});
|
|
611
477
|
const marshalUpdatePoolRequest = (request, defaults) => ({
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
478
|
+
autohealing: request.autohealing,
|
|
479
|
+
autoscaling: request.autoscaling,
|
|
480
|
+
kubelet_args: request.kubeletArgs,
|
|
481
|
+
max_size: request.maxSize,
|
|
482
|
+
min_size: request.minSize,
|
|
483
|
+
security_group_id: request.securityGroupId,
|
|
484
|
+
size: request.size,
|
|
485
|
+
tags: request.tags,
|
|
486
|
+
upgrade_policy: request.upgradePolicy !== void 0 ? marshalUpdatePoolRequestUpgradePolicy(request.upgradePolicy, defaults) : void 0
|
|
621
487
|
});
|
|
622
488
|
const marshalUpgradeClusterRequest = (request, defaults) => ({
|
|
623
|
-
|
|
624
|
-
|
|
489
|
+
upgrade_pools: request.upgradePools,
|
|
490
|
+
version: request.version
|
|
625
491
|
});
|
|
626
|
-
const marshalUpgradePoolRequest = (request, defaults) => ({
|
|
627
|
-
|
|
628
|
-
});
|
|
629
|
-
export {
|
|
630
|
-
marshalAddClusterACLRulesRequest,
|
|
631
|
-
marshalCreateClusterRequest,
|
|
632
|
-
marshalCreatePoolRequest,
|
|
633
|
-
marshalSetClusterACLRulesRequest,
|
|
634
|
-
marshalSetClusterTypeRequest,
|
|
635
|
-
marshalSetPoolLabelsRequest,
|
|
636
|
-
marshalSetPoolStartupTaintsRequest,
|
|
637
|
-
marshalSetPoolTaintsRequest,
|
|
638
|
-
marshalUpdateClusterRequest,
|
|
639
|
-
marshalUpdatePoolRequest,
|
|
640
|
-
marshalUpgradeClusterRequest,
|
|
641
|
-
marshalUpgradePoolRequest,
|
|
642
|
-
unmarshalAddClusterACLRulesResponse,
|
|
643
|
-
unmarshalCluster,
|
|
644
|
-
unmarshalExternalNode,
|
|
645
|
-
unmarshalExternalNodeAuth,
|
|
646
|
-
unmarshalListClusterACLRulesResponse,
|
|
647
|
-
unmarshalListClusterAvailableTypesResponse,
|
|
648
|
-
unmarshalListClusterAvailableVersionsResponse,
|
|
649
|
-
unmarshalListClusterTypesResponse,
|
|
650
|
-
unmarshalListClustersResponse,
|
|
651
|
-
unmarshalListNodesResponse,
|
|
652
|
-
unmarshalListPoolsResponse,
|
|
653
|
-
unmarshalListVersionsResponse,
|
|
654
|
-
unmarshalNode,
|
|
655
|
-
unmarshalNodeMetadata,
|
|
656
|
-
unmarshalPool,
|
|
657
|
-
unmarshalSetClusterACLRulesResponse,
|
|
658
|
-
unmarshalVersion
|
|
659
|
-
};
|
|
492
|
+
const marshalUpgradePoolRequest = (request, defaults) => ({ version: request.version });
|
|
493
|
+
export { marshalAddClusterACLRulesRequest, marshalCreateClusterRequest, marshalCreatePoolRequest, marshalSetClusterACLRulesRequest, marshalSetClusterTypeRequest, marshalSetPoolLabelsRequest, marshalSetPoolStartupTaintsRequest, marshalSetPoolTaintsRequest, marshalUpdateClusterRequest, marshalUpdatePoolRequest, marshalUpgradeClusterRequest, marshalUpgradePoolRequest, unmarshalAddClusterACLRulesResponse, unmarshalCluster, unmarshalExternalNode, unmarshalExternalNodeAuth, unmarshalListClusterACLRulesResponse, unmarshalListClusterAvailableTypesResponse, unmarshalListClusterAvailableVersionsResponse, unmarshalListClusterTypesResponse, unmarshalListClustersResponse, unmarshalListNodesResponse, unmarshalListPoolsResponse, unmarshalListVersionsResponse, unmarshalNode, unmarshalNodeMetadata, unmarshalPool, unmarshalSetClusterACLRulesResponse, unmarshalVersion };
|