@controlplane/schema 1.0.7 → 1.0.9

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.
Files changed (63) hide show
  1. package/build/src/interfaces/accessreport.d.ts +11 -11
  2. package/build/src/interfaces/agent.d.ts +14 -10
  3. package/build/src/interfaces/auditctx.d.ts +4 -4
  4. package/build/src/interfaces/base.d.ts +20 -20
  5. package/build/src/interfaces/cloudaccount.d.ts +7 -7
  6. package/build/src/interfaces/command.d.ts +155 -148
  7. package/build/src/interfaces/config.d.ts +2 -4
  8. package/build/src/interfaces/containerstatus.d.ts +6 -6
  9. package/build/src/interfaces/cronjob.d.ts +1 -1
  10. package/build/src/interfaces/dbcluster.d.ts +1 -1
  11. package/build/src/interfaces/deployment.d.ts +20 -20
  12. package/build/src/interfaces/domain.d.ts +67 -67
  13. package/build/src/interfaces/env.d.ts +1 -1
  14. package/build/src/interfaces/envoy.d.ts +5 -5
  15. package/build/src/interfaces/envoyAccessLog.d.ts +1 -1
  16. package/build/src/interfaces/envoyCluster.d.ts +9 -9
  17. package/build/src/interfaces/envoyCommon.d.ts +301 -301
  18. package/build/src/interfaces/envoyExcExtAuth.d.ts +2 -2
  19. package/build/src/interfaces/envoyHttp.d.ts +146 -146
  20. package/build/src/interfaces/envoyRateLimit.d.ts +1 -1
  21. package/build/src/interfaces/event.d.ts +9 -9
  22. package/build/src/interfaces/group.d.ts +2 -2
  23. package/build/src/interfaces/gvc.d.ts +185 -66
  24. package/build/src/interfaces/identity.d.ts +96 -63
  25. package/build/src/interfaces/image.d.ts +1 -1
  26. package/build/src/interfaces/ipSet.d.ts +14 -14
  27. package/build/src/interfaces/location.d.ts +16 -16
  28. package/build/src/interfaces/memcache.d.ts +7 -7
  29. package/build/src/interfaces/mk8s.d.ts +65 -65
  30. package/build/src/interfaces/mk8sAddons.d.ts +64 -64
  31. package/build/src/interfaces/mk8sAws.d.ts +9 -6
  32. package/build/src/interfaces/mk8sAzure.d.ts +10 -10
  33. package/build/src/interfaces/mk8sCommon.d.ts +26 -26
  34. package/build/src/interfaces/mk8sDigitalOcean.d.ts +2 -2
  35. package/build/src/interfaces/mk8sEphemeral.d.ts +1 -1
  36. package/build/src/interfaces/mk8sGcp.d.ts +9 -9
  37. package/build/src/interfaces/mk8sGeneric.d.ts +5 -5
  38. package/build/src/interfaces/mk8sHetzner.d.ts +10 -10
  39. package/build/src/interfaces/mk8sLambdalabs.d.ts +5 -5
  40. package/build/src/interfaces/mk8sLinode.d.ts +6 -6
  41. package/build/src/interfaces/mk8sOblivus.d.ts +5 -5
  42. package/build/src/interfaces/mk8sPaperspace.d.ts +5 -5
  43. package/build/src/interfaces/mk8sTriton.d.ts +23 -23
  44. package/build/src/interfaces/org.d.ts +32 -32
  45. package/build/src/interfaces/orgLogging.d.ts +32 -32
  46. package/build/src/interfaces/permissions.d.ts +1 -1
  47. package/build/src/interfaces/policy.d.ts +2 -2
  48. package/build/src/interfaces/policyMembership.d.ts +6 -6
  49. package/build/src/interfaces/query.d.ts +24 -17
  50. package/build/src/interfaces/quota.d.ts +1 -1
  51. package/build/src/interfaces/resourcePolicy.d.ts +1 -1
  52. package/build/src/interfaces/secret.d.ts +23 -23
  53. package/build/src/interfaces/serviceaccount.d.ts +7 -7
  54. package/build/src/interfaces/spicedb.d.ts +1 -1
  55. package/build/src/interfaces/statefulSet.d.ts +1 -1
  56. package/build/src/interfaces/task.d.ts +1 -1
  57. package/build/src/interfaces/tenant.d.ts +5 -5
  58. package/build/src/interfaces/tracing.d.ts +16 -8
  59. package/build/src/interfaces/user.d.ts +12 -12
  60. package/build/src/interfaces/volumeSet.d.ts +54 -46
  61. package/build/src/interfaces/workload.d.ts +203 -222
  62. package/build/src/interfaces/workloadOptions.d.ts +47 -14
  63. package/package.json +1 -1
@@ -1,67 +1,11 @@
1
- import { Regex, Kind, Tags, Links } from './base';
2
- import { EnvVar } from './env';
3
- import { VolumeSpec } from './volumeSpec';
4
- import { DefaultOptions, LocalOptions } from './workloadOptions';
5
- import { AccessLog } from './envoyAccessLog';
6
- import { Cluster } from './envoyCluster';
7
- import { ExcExtAuth, ExcludedRateLimit } from './envoyExcExtAuth';
8
- import { HttpFilter } from './envoyHttp';
9
- export type Memory = string;
10
- export type Cpu = string;
11
- export interface HealthCheckSpec {
12
- exec?: {
13
- command?: string[];
14
- };
15
- grpc?: {
16
- port?: number;
17
- };
18
- tcpSocket?: {
19
- port?: number;
20
- };
21
- httpGet?: {
22
- path?: string;
23
- port?: number;
24
- httpHeaders?: {
25
- name: string;
26
- value: string;
27
- }[];
28
- scheme?: 'HTTP' | 'HTTPS';
29
- };
30
- initialDelaySeconds?: number;
31
- periodSeconds?: number;
32
- timeoutSeconds?: number;
33
- successThreshold?: number;
34
- failureThreshold?: number;
35
- }
36
- export interface RolloutOptions {
37
- minReadySeconds?: number;
38
- maxUnavailableReplicas?: string;
39
- maxSurgeReplicas?: string;
40
- scalingPolicy?: 'OrderedReady' | 'Parallel';
41
- terminationGracePeriodSeconds?: number;
42
- }
43
- export interface RolloutOptionsStateful {
44
- minReadySeconds?: number;
45
- maxSurgeReplicas?: string;
46
- scalingPolicy?: 'OrderedReady' | 'Parallel';
47
- terminationGracePeriodSeconds?: number;
48
- maxUnavailableReplicas?: string;
49
- }
50
- export interface SecurityOptions {
51
- filesystemGroupId?: number;
52
- runAsUser?: number;
53
- }
54
- export interface GpuResource {
55
- nvidia?: {
56
- model?: any;
57
- quantity?: number;
58
- };
59
- custom?: {
60
- resource: string;
61
- runtimeClass?: string;
62
- quantity?: number;
63
- };
64
- }
1
+ import { Regex, Kind, Tags, Links } from './base.js';
2
+ import { EnvVar } from './env.js';
3
+ import { VolumeSpec } from './volumeSpec.js';
4
+ import { DefaultOptions, LocalOptions } from './workloadOptions.js';
5
+ import { AccessLog } from './envoyAccessLog.js';
6
+ import { Cluster } from './envoyCluster.js';
7
+ import { ExcExtAuth, ExcludedRateLimit } from './envoyExcExtAuth.js';
8
+ import { HttpFilter } from './envoyHttp.js';
65
9
  export interface ContainerSpec {
66
10
  name?: string;
67
11
  image: string;
@@ -159,67 +103,11 @@ export interface ContainerSpec {
159
103
  };
160
104
  volumes?: VolumeSpec[];
161
105
  }
162
- export interface HealthCheckStatus {
163
- active: boolean;
164
- success?: boolean;
165
- code?: number;
166
- message?: string;
167
- failures?: number;
168
- successes?: number;
169
- lastChecked?: Date;
170
- }
171
- export interface LoadBalancerStatus {
172
- origin?: string;
173
- url?: string;
174
- }
175
- export interface ResolvedImage {
176
- digest?: string;
177
- manifests?: {
178
- image: string;
179
- mediaType: string;
180
- digest: string;
181
- platform?: {
182
- [x: string]: string;
183
- };
184
- }[];
185
- }
186
- export interface ResolvedImages {
187
- resolvedForVersion?: number;
188
- resolvedAt?: Date;
189
- errorMessages?: string[];
190
- nextRetryAt?: Date;
191
- images?: ResolvedImage[];
192
- }
193
- export interface WorkloadStatus {
194
- parentId?: string;
195
- canonicalEndpoint?: string;
196
- endpoint?: string;
197
- internalName?: string;
198
- replicaInternalNames?: string[];
199
- healthCheck?: {
200
- active: boolean;
201
- success?: boolean;
202
- code?: number;
203
- message?: string;
204
- failures?: number;
205
- successes?: number;
206
- lastChecked?: Date;
207
- };
208
- currentReplicaCount?: number;
209
- resolvedImages?: {
210
- resolvedForVersion?: number;
211
- resolvedAt?: Date;
212
- errorMessages?: string[];
213
- nextRetryAt?: Date;
214
- images?: ResolvedImage[];
215
- };
216
- loadBalancer?: LoadBalancerStatus[];
217
- [x: string]: any;
218
- }
219
- export interface HeaderFilter {
220
- key: string;
221
- allowedValues?: Regex[];
222
- blockedValues?: Regex[];
106
+ export type Cpu = string;
107
+ export interface Extras {
108
+ affinity?: any;
109
+ tolerations?: any[];
110
+ topologySpreadConstraints?: any[];
223
111
  }
224
112
  export interface FirewallSpec {
225
113
  external?: {
@@ -241,7 +129,56 @@ export interface FirewallSpec {
241
129
  inboundAllowWorkload?: string[];
242
130
  };
243
131
  }
244
- export type ScheduleType = string;
132
+ export interface GpuResource {
133
+ nvidia?: {
134
+ model?: any;
135
+ quantity?: number;
136
+ };
137
+ custom?: {
138
+ resource: string;
139
+ runtimeClass?: string;
140
+ quantity?: number;
141
+ };
142
+ }
143
+ export interface HeaderFilter {
144
+ key: string;
145
+ allowedValues?: Regex[];
146
+ blockedValues?: Regex[];
147
+ }
148
+ export interface HealthCheckSpec {
149
+ exec?: {
150
+ command?: string[];
151
+ };
152
+ grpc?: {
153
+ port?: number;
154
+ };
155
+ tcpSocket?: {
156
+ port?: number;
157
+ };
158
+ httpGet?: {
159
+ path?: string;
160
+ port?: number;
161
+ httpHeaders?: {
162
+ name: string;
163
+ value: string;
164
+ }[];
165
+ scheme?: 'HTTP' | 'HTTPS';
166
+ };
167
+ initialDelaySeconds?: number;
168
+ periodSeconds?: number;
169
+ timeoutSeconds?: number;
170
+ successThreshold?: number;
171
+ failureThreshold?: number;
172
+ }
173
+ export interface HealthCheckStatus {
174
+ active: boolean;
175
+ success?: boolean;
176
+ code?: number;
177
+ message?: string;
178
+ failures?: number;
179
+ successes?: number;
180
+ lastChecked?: Date;
181
+ }
245
182
  export interface JobSpec {
246
183
  schedule: ScheduleType;
247
184
  concurrencyPolicy?: 'Forbid' | 'Replace' | 'Allow';
@@ -272,92 +209,54 @@ export interface LoadBalancerSpec {
272
209
  };
273
210
  replicaDirect?: boolean;
274
211
  }
275
- export interface Extras {
276
- affinity?: any;
277
- tolerations?: any[];
278
- topologySpreadConstraints?: any[];
212
+ export interface LoadBalancerStatus {
213
+ origin?: string;
214
+ url?: string;
215
+ }
216
+ export type Memory = string;
217
+ export interface PodZoneMap {
218
+ [x: string]: string;
279
219
  }
280
220
  export interface RequestRetryPolicy {
281
221
  attempts?: number;
282
222
  retryOn?: string[];
283
223
  }
284
- export type WorkloadType = 'serverless' | 'standard' | 'cron' | 'stateful';
285
- export interface WorkloadSpec {
286
- type?: WorkloadType;
287
- identityLink?: string;
288
- containers: ContainerSpec[];
289
- firewallConfig?: {
290
- external?: {
291
- inboundAllowCIDR?: string[];
292
- inboundBlockedCIDR?: string[];
293
- outboundAllowHostname?: string[];
294
- outboundAllowPort?: ({
295
- protocol: 'http' | 'https' | 'tcp';
296
- number: number;
297
- })[];
298
- outboundAllowCIDR?: string[];
299
- outboundBlockedCIDR?: string[];
300
- http?: {
301
- inboundHeaderFilter?: HeaderFilter[];
302
- };
303
- };
304
- internal?: {
305
- inboundAllowType?: 'none' | 'same-gvc' | 'same-org' | 'workload-list';
306
- inboundAllowWorkload?: string[];
307
- };
308
- };
309
- defaultOptions?: DefaultOptions;
310
- localOptions?: LocalOptions;
311
- job?: {
312
- schedule: ScheduleType;
313
- concurrencyPolicy?: 'Forbid' | 'Replace' | 'Allow';
314
- historyLimit?: number;
315
- restartPolicy?: 'OnFailure' | 'Never';
316
- activeDeadlineSeconds?: number;
317
- };
318
- sidecar?: {
319
- envoy?: {
320
- accessLog?: AccessLog[];
321
- clusters?: Cluster[];
322
- excludedExternalAuth?: ExcExtAuth[];
323
- excludedRateLimit?: ExcludedRateLimit[];
324
- http?: HttpFilter[];
325
- network?: any[];
326
- volumes?: VolumeSpec[];
327
- };
328
- };
329
- supportDynamicTags?: boolean;
330
- rolloutOptions?: any;
331
- securityOptions?: {
332
- filesystemGroupId?: number;
333
- runAsUser?: number;
334
- };
335
- loadBalancer?: {
336
- direct?: {
337
- enabled: boolean;
338
- ports?: LoadBalancerPort[];
339
- ipSet?: string;
340
- };
341
- geoLocation?: {
342
- enabled?: boolean;
343
- headers?: {
344
- asn?: string;
345
- city?: string;
346
- country?: string;
347
- region?: string;
348
- };
224
+ export interface ResolvedImage {
225
+ digest?: string;
226
+ manifests?: {
227
+ image: string;
228
+ mediaType: string;
229
+ digest: string;
230
+ platform?: {
231
+ [x: string]: string;
349
232
  };
350
- replicaDirect?: boolean;
351
- };
352
- extras?: {
353
- affinity?: any;
354
- tolerations?: any[];
355
- topologySpreadConstraints?: any[];
356
- };
357
- requestRetryPolicy?: {
358
- attempts?: number;
359
- retryOn?: string[];
360
- };
233
+ }[];
234
+ }
235
+ export interface ResolvedImages {
236
+ resolvedForVersion?: number;
237
+ resolvedAt?: Date;
238
+ errorMessages?: string[];
239
+ nextRetryAt?: Date;
240
+ images?: ResolvedImage[];
241
+ }
242
+ export interface RolloutOptions {
243
+ minReadySeconds?: number;
244
+ maxUnavailableReplicas?: string;
245
+ maxSurgeReplicas?: string;
246
+ scalingPolicy?: 'OrderedReady' | 'Parallel';
247
+ terminationGracePeriodSeconds?: number;
248
+ }
249
+ export interface RolloutOptionsStateful {
250
+ minReadySeconds?: number;
251
+ maxSurgeReplicas?: string;
252
+ scalingPolicy?: 'OrderedReady' | 'Parallel';
253
+ terminationGracePeriodSeconds?: number;
254
+ maxUnavailableReplicas?: string;
255
+ }
256
+ export type ScheduleType = string;
257
+ export interface SecurityOptions {
258
+ filesystemGroupId?: number;
259
+ runAsUser?: number;
361
260
  }
362
261
  export interface Workload {
363
262
  id?: string;
@@ -474,25 +373,107 @@ export interface Workload {
474
373
  [x: string]: any;
475
374
  };
476
375
  }
477
- export interface PodZoneMap {
478
- [x: string]: string;
479
- }
480
- export interface WorkloadConfig {
481
- scheduling?: {
482
- fingerprint?: string;
483
- version?: number;
376
+ export interface WorkloadSpec {
377
+ type?: WorkloadType;
378
+ identityLink?: string;
379
+ containers: ContainerSpec[];
380
+ firewallConfig?: {
381
+ external?: {
382
+ inboundAllowCIDR?: string[];
383
+ inboundBlockedCIDR?: string[];
384
+ outboundAllowHostname?: string[];
385
+ outboundAllowPort?: ({
386
+ protocol: 'http' | 'https' | 'tcp';
387
+ number: number;
388
+ })[];
389
+ outboundAllowCIDR?: string[];
390
+ outboundBlockedCIDR?: string[];
391
+ http?: {
392
+ inboundHeaderFilter?: HeaderFilter[];
393
+ };
394
+ };
395
+ internal?: {
396
+ inboundAllowType?: 'none' | 'same-gvc' | 'same-org' | 'workload-list';
397
+ inboundAllowWorkload?: string[];
398
+ };
484
399
  };
485
- thinProvision?: number;
486
- podZoneMap?: {
487
- [x: string]: string;
400
+ defaultOptions?: DefaultOptions;
401
+ localOptions?: LocalOptions;
402
+ job?: {
403
+ schedule: ScheduleType;
404
+ concurrencyPolicy?: 'Forbid' | 'Replace' | 'Allow';
405
+ historyLimit?: number;
406
+ restartPolicy?: 'OnFailure' | 'Never';
407
+ activeDeadlineSeconds?: number;
488
408
  };
489
- locationPodZoneMap?: {
490
- [x: string]: PodZoneMap;
409
+ sidecar?: {
410
+ envoy?: {
411
+ accessLog?: AccessLog[];
412
+ clusters?: Cluster[];
413
+ excludedExternalAuth?: ExcExtAuth[];
414
+ excludedRateLimit?: ExcludedRateLimit[];
415
+ http?: HttpFilter[];
416
+ network?: any[];
417
+ volumes?: VolumeSpec[];
418
+ };
491
419
  };
492
- proxy?: {
493
- minCpu?: number;
420
+ supportDynamicTags?: boolean;
421
+ rolloutOptions?: any;
422
+ securityOptions?: {
423
+ filesystemGroupId?: number;
424
+ runAsUser?: number;
494
425
  };
495
- subsets?: {
496
- enabled?: boolean;
426
+ loadBalancer?: {
427
+ direct?: {
428
+ enabled: boolean;
429
+ ports?: LoadBalancerPort[];
430
+ ipSet?: string;
431
+ };
432
+ geoLocation?: {
433
+ enabled?: boolean;
434
+ headers?: {
435
+ asn?: string;
436
+ city?: string;
437
+ country?: string;
438
+ region?: string;
439
+ };
440
+ };
441
+ replicaDirect?: boolean;
442
+ };
443
+ extras?: {
444
+ affinity?: any;
445
+ tolerations?: any[];
446
+ topologySpreadConstraints?: any[];
447
+ };
448
+ requestRetryPolicy?: {
449
+ attempts?: number;
450
+ retryOn?: string[];
497
451
  };
498
452
  }
453
+ export interface WorkloadStatus {
454
+ parentId?: string;
455
+ canonicalEndpoint?: string;
456
+ endpoint?: string;
457
+ internalName?: string;
458
+ replicaInternalNames?: string[];
459
+ healthCheck?: {
460
+ active: boolean;
461
+ success?: boolean;
462
+ code?: number;
463
+ message?: string;
464
+ failures?: number;
465
+ successes?: number;
466
+ lastChecked?: Date;
467
+ };
468
+ currentReplicaCount?: number;
469
+ resolvedImages?: {
470
+ resolvedForVersion?: number;
471
+ resolvedAt?: Date;
472
+ errorMessages?: string[];
473
+ nextRetryAt?: Date;
474
+ images?: ResolvedImage[];
475
+ };
476
+ loadBalancer?: LoadBalancerStatus[];
477
+ [x: string]: any;
478
+ }
479
+ export type WorkloadType = 'serverless' | 'standard' | 'cron' | 'stateful';
@@ -1,15 +1,3 @@
1
- export interface KedaTrigger {
2
- type: string;
3
- metadata?: {
4
- [x: string]: string | any;
5
- };
6
- name?: string;
7
- useCachedMetrics?: boolean;
8
- metricType?: 'AverageValue' | 'Value' | 'Utilization';
9
- authenticationRef?: {
10
- name: string;
11
- };
12
- }
13
1
  export interface DefaultOptions {
14
2
  autoscaling?: {
15
3
  metric?: 'concurrency' | 'cpu' | 'memory' | 'rps' | 'latency' | 'keda' | 'disabled';
@@ -53,7 +41,20 @@ export interface DefaultOptions {
53
41
  enabled?: boolean;
54
42
  };
55
43
  }
56
- export type LocalOptions = ({
44
+ export interface KedaTrigger {
45
+ type: string;
46
+ metadata?: {
47
+ [x: string]: string | any;
48
+ };
49
+ name?: string;
50
+ useCachedMetrics?: boolean;
51
+ metricType?: 'AverageValue' | 'Value' | 'Utilization';
52
+ authenticationRef?: {
53
+ name: string;
54
+ };
55
+ }
56
+ export type LocalOptions = LocalOptionsItem[];
57
+ export interface LocalOptionsItem {
57
58
  autoscaling?: {
58
59
  metric?: 'concurrency' | 'cpu' | 'memory' | 'rps' | 'latency' | 'keda' | 'disabled';
59
60
  multi?: {
@@ -96,4 +97,36 @@ export type LocalOptions = ({
96
97
  enabled?: boolean;
97
98
  };
98
99
  location: string;
99
- })[];
100
+ }
101
+ export interface OptionsAutoscaling {
102
+ metric?: 'concurrency' | 'cpu' | 'memory' | 'rps' | 'latency' | 'keda' | 'disabled';
103
+ multi?: {
104
+ metric?: any;
105
+ target?: number;
106
+ }[];
107
+ metricPercentile?: 'p50' | 'p75' | 'p99';
108
+ target?: number;
109
+ maxScale?: number;
110
+ minScale?: number;
111
+ scaleToZeroDelay?: number;
112
+ maxConcurrency?: number;
113
+ keda?: {
114
+ triggers?: KedaTrigger[];
115
+ advanced?: {
116
+ scalingModifiers?: {
117
+ target?: string;
118
+ activationTarget?: string;
119
+ metricType?: 'AverageValue' | 'Value' | 'Utilization';
120
+ formula?: string;
121
+ };
122
+ };
123
+ fallback?: {
124
+ failureThreshold: number;
125
+ replicas: number;
126
+ behavior?: 'static' | 'currentReplicas' | 'currentReplicasIfHigher' | 'currentReplicasIfLower';
127
+ };
128
+ pollingInterval?: number;
129
+ cooldownPeriod?: number;
130
+ initialCooldownPeriod?: number;
131
+ };
132
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@controlplane/schema",
3
- "version": "1.0.7",
3
+ "version": "1.0.9",
4
4
  "description": "Control Plane Corporation Schema",
5
5
  "scripts": {
6
6
  "build": "tsc",