@controlplane/schema 1.0.2 → 1.0.4

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 (47) hide show
  1. package/build/src/interfaces/command.d.ts +175 -1
  2. package/build/src/interfaces/discovery.d.ts +2 -0
  3. package/build/src/interfaces/domain.d.ts +2 -1
  4. package/build/src/interfaces/envoy.d.ts +14 -0
  5. package/build/src/interfaces/envoy.js +3 -0
  6. package/build/src/interfaces/envoyAccessLog.d.ts +21 -0
  7. package/build/src/interfaces/envoyAccessLog.js +3 -0
  8. package/build/src/interfaces/envoyCluster.d.ts +64 -0
  9. package/build/src/interfaces/envoyCluster.js +3 -0
  10. package/build/src/interfaces/envoyCommon.d.ts +437 -0
  11. package/build/src/interfaces/envoyCommon.js +3 -0
  12. package/build/src/interfaces/envoyExcExtAuth.d.ts +12 -0
  13. package/build/src/interfaces/envoyExcExtAuth.js +3 -0
  14. package/build/src/interfaces/envoyHttp.d.ts +273 -0
  15. package/build/src/interfaces/envoyHttp.js +3 -0
  16. package/build/src/interfaces/envoyRateLimit.d.ts +45 -0
  17. package/build/src/interfaces/envoyRateLimit.js +3 -0
  18. package/build/src/interfaces/gvc.d.ts +7 -3
  19. package/build/src/interfaces/identity.d.ts +4 -0
  20. package/build/src/interfaces/mk8s.d.ts +27 -3
  21. package/build/src/interfaces/mk8sAddons.d.ts +20 -2
  22. package/build/src/interfaces/mk8sAws.d.ts +12 -3
  23. package/build/src/interfaces/mk8sCommon.d.ts +5 -1
  24. package/build/src/interfaces/mk8sEphemeral.d.ts +18 -0
  25. package/build/src/interfaces/mk8sEphemeral.js +3 -0
  26. package/build/src/interfaces/mk8sGeneric.d.ts +4 -0
  27. package/build/src/interfaces/mk8sHetzner.d.ts +10 -1
  28. package/build/src/interfaces/mk8sLambdalabs.d.ts +1 -1
  29. package/build/src/interfaces/mk8sLinode.d.ts +2 -1
  30. package/build/src/interfaces/mk8sPaperspace.d.ts +2 -1
  31. package/build/src/interfaces/org.d.ts +26 -2
  32. package/build/src/interfaces/orgLogging.d.ts +25 -0
  33. package/build/src/interfaces/port.d.ts +1 -0
  34. package/build/src/interfaces/port.js +3 -0
  35. package/build/src/interfaces/secret.d.ts +1 -0
  36. package/build/src/interfaces/tracing.d.ts +9 -0
  37. package/build/src/interfaces/util.d.ts +0 -0
  38. package/build/src/interfaces/util.js +2 -0
  39. package/build/src/interfaces/valkey.d.ts +0 -0
  40. package/build/src/interfaces/valkey.js +2 -0
  41. package/build/src/interfaces/volumeSet.d.ts +15 -14
  42. package/build/src/interfaces/volumeSpec.d.ts +5 -0
  43. package/build/src/interfaces/volumeSpec.js +3 -0
  44. package/build/src/interfaces/workload.d.ts +15 -60
  45. package/build/src/interfaces/workloadOptions.d.ts +18 -0
  46. package/build/src/interfaces/workloadOptions.js +3 -0
  47. package/package.json +1 -1
@@ -1,8 +1,11 @@
1
- import { Kind, Links } from './base';
1
+ import { Kind, Links, ImageLink, Name, Tags } from './base';
2
2
  import { EnvVar } from './env';
3
+ import { Memory, Cpu } from './workload';
4
+ import { VolumeSnapshot, SnapshotSpec, VolumeSetStatus } from './volumeSet';
3
5
  export type CommandLifecycleStage = 'pending' | 'running' | 'cancelled' | 'completed' | 'failed';
4
6
  export interface Command {
5
7
  id?: string;
8
+ ownerId?: string;
6
9
  kind?: Kind;
7
10
  version?: number;
8
11
  created?: Date;
@@ -22,8 +25,179 @@ export interface CronWorkloadContainerOverrides {
22
25
  env?: EnvVar[];
23
26
  command?: string;
24
27
  args?: string[];
28
+ memory?: Memory;
29
+ cpu?: Cpu;
30
+ image?: ImageLink;
25
31
  }
26
32
  export interface RunCronWorkloadSpec {
27
33
  location: string;
28
34
  containerOverrides?: CronWorkloadContainerOverrides[];
29
35
  }
36
+ export interface RunCronWorkloadStatus {
37
+ replica?: string;
38
+ }
39
+ export interface StopReplicaSpec {
40
+ location: string;
41
+ replica?: string;
42
+ }
43
+ export interface StopReplicaStatus {
44
+ clusterId?: string;
45
+ podCreatedByCommandLink?: string;
46
+ podId: string;
47
+ }
48
+ export interface ReplaceVolumeSpec {
49
+ location: string;
50
+ volumeIndex: number;
51
+ }
52
+ export interface RestoreVolumeSpec {
53
+ location: string;
54
+ volumeIndex: number;
55
+ snapshotName: string;
56
+ }
57
+ export interface ReplaceVolumeStatus {
58
+ stage: 'create-volume' | 'cleanup-after-volume-creation' | 'update-volume-set' | 'shutdown-replica' | 'await-replica-termination' | 'restart-replica' | 'cleanup-k8s' | 'cleanup-old-storage-device' | 'revert';
59
+ messages?: string[];
60
+ clusterId?: string;
61
+ inUseByWorkloadId?: string;
62
+ storageDeviceIdToRemove?: string;
63
+ newStorageDeviceId?: string;
64
+ nextVolumeSize?: number;
65
+ }
66
+ export interface CreateVolumeSnapshotSpec {
67
+ location: string;
68
+ volumeIndex: number;
69
+ snapshotName: string;
70
+ snapshotExpirationDate?: Date;
71
+ snapshotTags?: {
72
+ [x: string]: string;
73
+ }[];
74
+ }
75
+ export interface CreateVolumeSnapshotStatus {
76
+ stage: 'create-snapshot' | 'update-volume-set' | 'cleanup-k8s' | 'revert';
77
+ messages?: string[];
78
+ clusterId?: string;
79
+ newSnapshotId?: string;
80
+ newSnapshotSize?: number;
81
+ creationStartTime?: Date;
82
+ }
83
+ export interface ExpandVolumeSpec {
84
+ location: string;
85
+ volumeIndex: number;
86
+ newStorageCapacity: number;
87
+ }
88
+ export interface ExpandVolumeStatus {
89
+ clusterId?: string;
90
+ messages?: string[];
91
+ stage: 'expand-volume' | 'await-replica-termination' | 'await-expansion-completed' | 'update-volume-set' | 'recreate-replica' | 'cleanup-k8s' | 'revert';
92
+ replicaRestartedAt?: Date;
93
+ }
94
+ export interface DeleteVolumeSpec {
95
+ location: string;
96
+ volumeIndex: number;
97
+ }
98
+ export interface SnapshotDeletionStatus {
99
+ stage?: 'pending' | 'k8s-resources-created' | 'deleted';
100
+ messages?: string[];
101
+ }
102
+ export interface DeleteVolumeStatus {
103
+ clusterId?: string;
104
+ volume: {
105
+ lifecycle?: 'creating' | 'unused' | 'unbound' | 'bound' | 'deleted' | 'repairing';
106
+ storageDeviceId?: string;
107
+ index: number;
108
+ currentSize: number;
109
+ currentBytesUsed?: number;
110
+ iops?: number;
111
+ throughput?: number;
112
+ driver: string;
113
+ volumeSnapshots?: VolumeSnapshot[];
114
+ attributes?: {
115
+ [x: string]: string;
116
+ };
117
+ };
118
+ stage: 'delete-snapshots' | 'delete-volume' | 'finalize-volume-deletion' | 'update-volume-set';
119
+ messages?: string[];
120
+ pvcRef?: {
121
+ namespace: string;
122
+ name: string;
123
+ };
124
+ snapshotDeletionStatus: {
125
+ [x: string]: SnapshotDeletionStatus;
126
+ };
127
+ }
128
+ export interface DeleteVolumeSnapshotSpec {
129
+ location: string;
130
+ volumeIndex: number;
131
+ snapshotName: string;
132
+ }
133
+ export interface DeleteVolumeSnapshotStatus {
134
+ clusterId?: string;
135
+ snapshot: {
136
+ name: string;
137
+ id?: string;
138
+ created: Date;
139
+ expires?: Date;
140
+ size?: number;
141
+ tags?: {
142
+ [x: string]: string;
143
+ }[];
144
+ };
145
+ stage: 'delete-snapshot' | 'update-volume-set';
146
+ messages?: string[];
147
+ }
148
+ export interface Cluster {
149
+ clusterId?: string;
150
+ since?: Date;
151
+ }
152
+ export interface Clusters {
153
+ [x: string]: Cluster;
154
+ }
155
+ export interface DeleteVolumeSetSpec {
156
+ volumeSet: {
157
+ id?: string;
158
+ name?: Name;
159
+ kind?: Kind;
160
+ version?: number;
161
+ description?: string;
162
+ tags?: Tags;
163
+ created?: Date;
164
+ lastModified?: Date;
165
+ links?: Links;
166
+ spec: {
167
+ initialCapacity: number;
168
+ performanceClass: 'general-purpose-ssd' | 'high-throughput-ssd';
169
+ storageClassSuffix?: string;
170
+ fileSystemType?: 'xfs' | 'ext4';
171
+ snapshots?: SnapshotSpec;
172
+ autoscaling?: {
173
+ maxCapacity?: number;
174
+ minFreePercentage?: number;
175
+ scalingFactor?: number;
176
+ };
177
+ };
178
+ status?: VolumeSetStatus;
179
+ gvc?: any;
180
+ };
181
+ }
182
+ export interface DeleteVolumeSetLocationStatus {
183
+ stage: 'delete-volumes' | 'delete-orphaned-volumes' | 'complete';
184
+ volumes?: {
185
+ [x: string]: DeleteVolumeStatus;
186
+ };
187
+ }
188
+ export interface DeleteVolumeSetStatus {
189
+ [x: string]: DeleteVolumeSetLocationStatus;
190
+ }
191
+ export interface DeleteOrphanedVolumeSpec {
192
+ storageDeviceId: string;
193
+ org: string;
194
+ gvc: string;
195
+ workloadName: string;
196
+ volumeSetUri: string;
197
+ driver: string;
198
+ }
199
+ export interface DeleteOrphanedVolumeStatus {
200
+ clusterId?: string;
201
+ stage?: 'create-deletion-records' | 'delete' | 'cleanup-k8s';
202
+ messages?: string[];
203
+ }
@@ -8,6 +8,8 @@ export interface Discovery {
8
8
  audit?: string;
9
9
  logs?: string;
10
10
  metrics?: string;
11
+ tracing?: string;
12
+ byok?: string;
11
13
  metering?: string;
12
14
  "billing-ng"?: string;
13
15
  grafana?: string;
@@ -1,7 +1,8 @@
1
1
  import { LocalLink, Kind, Tags, Links } from './base';
2
2
  export interface Route {
3
- prefix?: string;
4
3
  replacePrefix?: string;
4
+ regex?: string;
5
+ prefix?: string;
5
6
  workloadLink: string;
6
7
  port?: number;
7
8
  hostPrefix?: string;
@@ -0,0 +1,14 @@
1
+ import { AccessLog } from './envoyAccessLog';
2
+ import { Cluster } from './envoyCluster';
3
+ import { ExcExtAuth, ExcludedRateLimit } from './envoyExcExtAuth';
4
+ import { HttpFilter } from './envoyHttp';
5
+ import { VolumeSpec } from './volumeSpec';
6
+ export interface EnvoyFilters {
7
+ accessLog?: AccessLog[];
8
+ clusters?: Cluster[];
9
+ excludedExternalAuth?: ExcExtAuth[];
10
+ excludedRateLimit?: ExcludedRateLimit[];
11
+ http?: HttpFilter[];
12
+ network?: any[];
13
+ volumes?: VolumeSpec[];
14
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ /* auto-generated */
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,21 @@
1
+ import { Priority, GrpcService, ApiVersion, Duration, UInt32, RetryPolicy } from './envoyCommon';
2
+ export interface AccessLog {
3
+ priority?: Priority;
4
+ name?: 'envoy.http_grpc_access_log';
5
+ excludedWorkloads?: string[];
6
+ typed_config?: {
7
+ "@type"?: any;
8
+ common_config?: {
9
+ log_name: string;
10
+ grpc_service?: GrpcService;
11
+ transport_api_version?: ApiVersion;
12
+ buffer_flush_interval?: Duration;
13
+ buffer_size_bytes?: UInt32;
14
+ filter_state_objects_to_log?: string[];
15
+ grpc_stream_retry_policy?: RetryPolicy;
16
+ };
17
+ additional_request_headers_to_log?: string[];
18
+ additional_response_headers_to_log?: string[];
19
+ additional_response_trailers_to_log?: string[];
20
+ };
21
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ /* auto-generated */
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,64 @@
1
+ import { Struct } from './envoyCommon';
2
+ export interface Metadata {
3
+ filter_metadata?: {
4
+ [x: string]: Struct;
5
+ };
6
+ typed_filter_metadata?: {
7
+ [x: string]: any;
8
+ };
9
+ }
10
+ export interface Cluster {
11
+ name: string;
12
+ excludedWorkloads?: string[];
13
+ transport_socket_matches?: any;
14
+ alt_stat_name?: any;
15
+ type?: 'STATIC' | 'STRICT_DNS' | 'LOGICAL_DNS' | 'EDS' | 'ORIGINAL_DST';
16
+ cluster_type?: any;
17
+ eds_cluster_config?: any;
18
+ connect_timeout?: any;
19
+ per_connection_buffer_limit_bytes?: any;
20
+ lb_policy?: any;
21
+ load_assignment?: {
22
+ cluster_name: string;
23
+ endpoints?: any;
24
+ policy?: any;
25
+ };
26
+ health_checks?: any;
27
+ max_requests_per_connection?: any;
28
+ circuit_breakers?: any;
29
+ upstream_http_protocol_options?: any;
30
+ common_http_protocol_options?: any;
31
+ http_protocol_options?: any;
32
+ http2_protocol_options?: any;
33
+ typed_extension_protocol_options?: any;
34
+ dns_refresh_rate?: any;
35
+ dns_failure_refresh_rate?: any;
36
+ respect_dns_ttl?: any;
37
+ dns_lookup_family?: any;
38
+ dns_resolvers?: any;
39
+ use_tcp_for_dns_lookups?: any;
40
+ dns_resolution_config?: any;
41
+ typed_dns_resolver_config?: any;
42
+ wait_for_warm_on_init?: any;
43
+ outlier_detection?: any;
44
+ cleanup_interval?: any;
45
+ upstream_bind_config?: any;
46
+ lb_subset_config?: any;
47
+ ring_hash_lb_config?: any;
48
+ maglev_lb_config?: any;
49
+ least_request_lb_config?: any;
50
+ common_lb_config?: any;
51
+ transport_socket?: any;
52
+ metadata?: any;
53
+ protocol_selection?: any;
54
+ upstream_connection_options?: any;
55
+ close_connections_on_host_health_failure?: any;
56
+ ignore_health_on_host_removal?: any;
57
+ filters?: any;
58
+ load_balancing_policy?: any;
59
+ track_timeout_budgets?: any;
60
+ upstream_config?: any;
61
+ track_cluster_stats?: any;
62
+ preconnect_policy?: any;
63
+ connection_pool_per_downstream_connection?: any;
64
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ /* auto-generated */
3
+ Object.defineProperty(exports, "__esModule", { value: true });