@scaleway/sdk-container 2.4.2 → 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/dist/index.gen.d.ts +1 -0
- package/dist/index.gen.js +3 -2
- package/dist/metadata.gen.d.ts +12 -0
- package/dist/metadata.gen.js +9 -0
- package/dist/metadata.gen.json +6 -0
- package/dist/metadata2.gen.js +8 -0
- package/dist/v1/api.gen.d.ts +226 -0
- package/dist/v1/api.gen.js +310 -0
- package/dist/v1/content.gen.d.ts +9 -0
- package/dist/v1/content.gen.js +35 -0
- package/dist/v1/index.gen.d.ts +5 -0
- package/dist/v1/index.gen.js +32 -0
- package/dist/v1/marshalling.gen.d.ts +18 -0
- package/dist/v1/marshalling.gen.js +373 -0
- package/dist/v1/metadata.gen.d.ts +103 -0
- package/dist/v1/metadata.gen.js +115 -0
- package/dist/v1/types.gen.d.ts +1109 -0
- package/dist/v1/types.gen.js +0 -0
- package/dist/v1/validation-rules.gen.d.ts +263 -0
- package/dist/v1/validation-rules.gen.js +225 -0
- package/dist/v1beta1/api.gen.d.ts +10 -2
- package/dist/v1beta1/api.gen.js +10 -2
- package/dist/v1beta1/metadata.gen.d.ts +136 -0
- package/dist/v1beta1/metadata.gen.js +151 -0
- package/dist/v1beta1/types.gen.d.ts +5 -5
- package/package.json +10 -2
|
@@ -0,0 +1,1109 @@
|
|
|
1
|
+
import type { Region as ScwRegion } from '@scaleway/sdk-client';
|
|
2
|
+
export type ContainerPrivacy = 'unknown_privacy' | 'public' | 'private';
|
|
3
|
+
export type ContainerProtocol = 'unknown_protocol' | 'http1' | 'h2c';
|
|
4
|
+
export type ContainerSandbox = 'unknown_sandbox' | 'v1' | 'v2';
|
|
5
|
+
export type ContainerStatus = 'unknown_status' | 'updating' | 'deleting' | 'locking' | 'ready' | 'error' | 'locked' | 'creating' | 'upgrading';
|
|
6
|
+
export type CreateTriggerRequestDestinationConfigHttpMethod = 'unknown_http_method' | 'get' | 'post' | 'put' | 'patch' | 'delete';
|
|
7
|
+
export type DomainStatus = 'unknown_status' | 'creating' | 'updating' | 'deleting' | 'ready' | 'error' | 'locked' | 'locking' | 'upgrading';
|
|
8
|
+
export type ListContainersRequestOrderBy = 'created_at_asc' | 'created_at_desc' | 'name_asc' | 'name_desc';
|
|
9
|
+
export type ListDomainsRequestOrderBy = 'created_at_asc' | 'created_at_desc' | 'hostname_asc' | 'hostname_desc';
|
|
10
|
+
export type ListNamespacesRequestOrderBy = 'created_at_asc' | 'created_at_desc' | 'name_asc' | 'name_desc';
|
|
11
|
+
export type ListTriggersRequestOrderBy = 'created_at_asc' | 'created_at_desc' | 'name_asc' | 'name_desc';
|
|
12
|
+
export type NamespaceStatus = 'unknown_status' | 'updating' | 'deleting' | 'locking' | 'ready' | 'error' | 'locked' | 'creating' | 'upgrading';
|
|
13
|
+
export type TriggerDestinationConfigHttpMethod = 'unknown_http_method' | 'get' | 'post' | 'put' | 'patch' | 'delete';
|
|
14
|
+
export type TriggerSourceType = 'unknown_source_type' | 'cron' | 'sqs' | 'nats';
|
|
15
|
+
export type TriggerStatus = 'unknown_status' | 'ready' | 'deleting' | 'error' | 'updating' | 'creating' | 'locking' | 'locked' | 'upgrading';
|
|
16
|
+
export type UpdateTriggerRequestDestinationConfigHttpMethod = 'unknown_http_method' | 'get' | 'post' | 'put' | 'patch' | 'delete';
|
|
17
|
+
export interface ContainerProbeHTTPProbe {
|
|
18
|
+
/**
|
|
19
|
+
* HTTP path to perform the check on.
|
|
20
|
+
*/
|
|
21
|
+
path: string;
|
|
22
|
+
}
|
|
23
|
+
export interface ContainerProbeTCPProbe {
|
|
24
|
+
}
|
|
25
|
+
export interface ContainerProbe {
|
|
26
|
+
/**
|
|
27
|
+
* Unhealthy containers do not receive traffic from incoming requests.
|
|
28
|
+
*/
|
|
29
|
+
failureThreshold: number;
|
|
30
|
+
/**
|
|
31
|
+
* Time interval between checks.
|
|
32
|
+
*/
|
|
33
|
+
interval?: string;
|
|
34
|
+
/**
|
|
35
|
+
* Duration before the check times out.
|
|
36
|
+
*/
|
|
37
|
+
timeout?: string;
|
|
38
|
+
/**
|
|
39
|
+
* The check is successful if a TCP connection can be established with the container within the specified timeout.
|
|
40
|
+
*
|
|
41
|
+
* One-of ('probe'): at most one of 'tcp', 'http' could be set.
|
|
42
|
+
*/
|
|
43
|
+
tcp?: ContainerProbeTCPProbe;
|
|
44
|
+
/**
|
|
45
|
+
* The check is successful if an HTTP request to the specified path returns a successful status code (e.g. 2XX or 3XX) within the specified timeout.
|
|
46
|
+
*
|
|
47
|
+
* One-of ('probe'): at most one of 'tcp', 'http' could be set.
|
|
48
|
+
*/
|
|
49
|
+
http?: ContainerProbeHTTPProbe;
|
|
50
|
+
}
|
|
51
|
+
export interface ContainerScalingOption {
|
|
52
|
+
/**
|
|
53
|
+
* Scale depending on the number of concurrent requests being processed per container instance. The threshold value is the number of concurrent requests above which the container will be scaled up.
|
|
54
|
+
*
|
|
55
|
+
* One-of ('scalingRule'): at most one of 'concurrentRequestsThreshold', 'cpuUsageThreshold', 'memoryUsageThreshold' could be set.
|
|
56
|
+
*/
|
|
57
|
+
concurrentRequestsThreshold?: number;
|
|
58
|
+
/**
|
|
59
|
+
* Scale depending on the CPU usage of a container instance. The threshold value is the percentage of CPU usage above which the container will be scaled up.
|
|
60
|
+
*
|
|
61
|
+
* One-of ('scalingRule'): at most one of 'concurrentRequestsThreshold', 'cpuUsageThreshold', 'memoryUsageThreshold' could be set.
|
|
62
|
+
*/
|
|
63
|
+
cpuUsageThreshold?: number;
|
|
64
|
+
/**
|
|
65
|
+
* Scale depending on the memory usage of a container instance. The threshold value is the percentage of memory usage above which the container will be scaled up.
|
|
66
|
+
*
|
|
67
|
+
* One-of ('scalingRule'): at most one of 'concurrentRequestsThreshold', 'cpuUsageThreshold', 'memoryUsageThreshold' could be set.
|
|
68
|
+
*/
|
|
69
|
+
memoryUsageThreshold?: number;
|
|
70
|
+
}
|
|
71
|
+
export interface TriggerCronConfig {
|
|
72
|
+
/**
|
|
73
|
+
* UNIX cron schedule to run job (e.g., "* * * * *").
|
|
74
|
+
*/
|
|
75
|
+
schedule: string;
|
|
76
|
+
/**
|
|
77
|
+
* Timezone for the cron schedule, in tz database format (e.g., "Europe/Paris").
|
|
78
|
+
*/
|
|
79
|
+
timezone: string;
|
|
80
|
+
/**
|
|
81
|
+
* Body to send to the container when the trigger is invoked.
|
|
82
|
+
*/
|
|
83
|
+
body: string;
|
|
84
|
+
/**
|
|
85
|
+
* Additional headers to send to the container when the trigger is invoked.
|
|
86
|
+
*/
|
|
87
|
+
headers: Record<string, string>;
|
|
88
|
+
}
|
|
89
|
+
export interface TriggerDestinationConfig {
|
|
90
|
+
/**
|
|
91
|
+
* The HTTP path to send the request to (e.g., "/my-webhook-endpoint").
|
|
92
|
+
*/
|
|
93
|
+
httpPath: string;
|
|
94
|
+
/**
|
|
95
|
+
* The HTTP method to use when sending the request (e.g., get, post, put, patch, delete). Must be specified as lowercase.
|
|
96
|
+
*/
|
|
97
|
+
httpMethod: TriggerDestinationConfigHttpMethod;
|
|
98
|
+
}
|
|
99
|
+
export interface TriggerNATSConfig {
|
|
100
|
+
/**
|
|
101
|
+
* The URLs of the NATS servers (e.g., "nats://nats.mnq.fr-par.scaleway.com:4222").
|
|
102
|
+
*/
|
|
103
|
+
serverUrls: string[];
|
|
104
|
+
/**
|
|
105
|
+
* NATS subject to subscribe to (e.g., "my-subject").
|
|
106
|
+
*/
|
|
107
|
+
subject: string;
|
|
108
|
+
}
|
|
109
|
+
export interface TriggerSQSConfig {
|
|
110
|
+
/**
|
|
111
|
+
* The region where the SQS queue is hosted (e.g., "fr-par", "nl-ams").
|
|
112
|
+
*/
|
|
113
|
+
region: ScwRegion;
|
|
114
|
+
/**
|
|
115
|
+
* Endpoint URL to use to access SQS (e.g., "https://sqs.mnq.fr-par.scaleway.com").
|
|
116
|
+
*/
|
|
117
|
+
endpoint: string;
|
|
118
|
+
/**
|
|
119
|
+
* The access key for accessing the SQS queue.
|
|
120
|
+
*/
|
|
121
|
+
accessKeyId: string;
|
|
122
|
+
/**
|
|
123
|
+
* The URL of the SQS queue to monitor for messages.
|
|
124
|
+
*/
|
|
125
|
+
queueUrl: string;
|
|
126
|
+
}
|
|
127
|
+
export interface UpdateContainerRequestProbeHTTPProbe {
|
|
128
|
+
path?: string;
|
|
129
|
+
}
|
|
130
|
+
export interface UpdateContainerRequestProbeTCPProbe {
|
|
131
|
+
}
|
|
132
|
+
export interface CreateTriggerRequestCronConfig {
|
|
133
|
+
/**
|
|
134
|
+
* UNIX cron schedule to run job (e.g., "* * * * *").
|
|
135
|
+
*/
|
|
136
|
+
schedule: string;
|
|
137
|
+
/**
|
|
138
|
+
* Timezone for the cron schedule, in tz database format (e.g., "Europe/Paris").
|
|
139
|
+
*/
|
|
140
|
+
timezone: string;
|
|
141
|
+
/**
|
|
142
|
+
* Body to send to the container when the trigger is invoked.
|
|
143
|
+
*/
|
|
144
|
+
body: string;
|
|
145
|
+
/**
|
|
146
|
+
* Additional headers to send to the container when the trigger is invoked.
|
|
147
|
+
*/
|
|
148
|
+
headers: Record<string, string>;
|
|
149
|
+
}
|
|
150
|
+
export interface CreateTriggerRequestDestinationConfig {
|
|
151
|
+
/**
|
|
152
|
+
* The HTTP path to send the request to (e.g., "/my-webhook-endpoint").
|
|
153
|
+
*/
|
|
154
|
+
httpPath: string;
|
|
155
|
+
/**
|
|
156
|
+
* The HTTP method to use when sending the request (e.g., get, post, put, patch, delete). Must be specified as lowercase.
|
|
157
|
+
*/
|
|
158
|
+
httpMethod: CreateTriggerRequestDestinationConfigHttpMethod;
|
|
159
|
+
}
|
|
160
|
+
export interface CreateTriggerRequestNATSConfig {
|
|
161
|
+
/**
|
|
162
|
+
* The URLs of the NATS server (e.g., "nats://nats.mnq.fr-par.scaleway.com:4222").
|
|
163
|
+
*/
|
|
164
|
+
serverUrls: string[];
|
|
165
|
+
/**
|
|
166
|
+
* NATS subject to subscribe to (e.g., "my-subject").
|
|
167
|
+
*/
|
|
168
|
+
subject: string;
|
|
169
|
+
/**
|
|
170
|
+
* The credentials from this file will be used to authenticate with the NATS server and subscribe to the specified subject.
|
|
171
|
+
*/
|
|
172
|
+
credentialsFileContent: string;
|
|
173
|
+
}
|
|
174
|
+
export interface CreateTriggerRequestSQSConfig {
|
|
175
|
+
/**
|
|
176
|
+
* The region where the SQS queue is hosted (e.g., "fr-par", "nl-ams").
|
|
177
|
+
*/
|
|
178
|
+
region: ScwRegion;
|
|
179
|
+
/**
|
|
180
|
+
* Endpoint URL to use to access SQS (e.g., "https://sqs.mnq.fr-par.scaleway.com").
|
|
181
|
+
*/
|
|
182
|
+
endpoint: string;
|
|
183
|
+
/**
|
|
184
|
+
* The access key for accessing the SQS queue.
|
|
185
|
+
*/
|
|
186
|
+
accessKeyId: string;
|
|
187
|
+
/**
|
|
188
|
+
* The secret key for accessing the SQS queue.
|
|
189
|
+
*/
|
|
190
|
+
secretAccessKey: string;
|
|
191
|
+
/**
|
|
192
|
+
* The URL of the SQS queue to monitor for messages.
|
|
193
|
+
*/
|
|
194
|
+
queueUrl: string;
|
|
195
|
+
}
|
|
196
|
+
export interface Container {
|
|
197
|
+
/**
|
|
198
|
+
* Container unique ID.
|
|
199
|
+
*/
|
|
200
|
+
id: string;
|
|
201
|
+
/**
|
|
202
|
+
* Container name.
|
|
203
|
+
*/
|
|
204
|
+
name: string;
|
|
205
|
+
/**
|
|
206
|
+
* Unique ID of the namespace the container belongs to.
|
|
207
|
+
*/
|
|
208
|
+
namespaceId: string;
|
|
209
|
+
/**
|
|
210
|
+
* Container description.
|
|
211
|
+
*/
|
|
212
|
+
description: string;
|
|
213
|
+
/**
|
|
214
|
+
* Container status.
|
|
215
|
+
*/
|
|
216
|
+
status: ContainerStatus;
|
|
217
|
+
/**
|
|
218
|
+
* Container last error message.
|
|
219
|
+
*/
|
|
220
|
+
errorMessage?: string;
|
|
221
|
+
/**
|
|
222
|
+
* Container creation date.
|
|
223
|
+
*/
|
|
224
|
+
createdAt?: Date;
|
|
225
|
+
/**
|
|
226
|
+
* Container last update date.
|
|
227
|
+
*/
|
|
228
|
+
updatedAt?: Date;
|
|
229
|
+
/**
|
|
230
|
+
* Environment variables of the container.
|
|
231
|
+
*/
|
|
232
|
+
environmentVariables: Record<string, string>;
|
|
233
|
+
/**
|
|
234
|
+
* Secret environment variables of the container.
|
|
235
|
+
*/
|
|
236
|
+
secretEnvironmentVariables: Record<string, string>;
|
|
237
|
+
/**
|
|
238
|
+
* Minimum number of instances to scale the container to.
|
|
239
|
+
*/
|
|
240
|
+
minScale: number;
|
|
241
|
+
/**
|
|
242
|
+
* Maximum number of instances to scale the container to.
|
|
243
|
+
*/
|
|
244
|
+
maxScale: number;
|
|
245
|
+
/**
|
|
246
|
+
* Memory limit of the container in bytes.
|
|
247
|
+
*/
|
|
248
|
+
memoryLimitBytes: number;
|
|
249
|
+
/**
|
|
250
|
+
* CPU limit of the container in mvCPU.
|
|
251
|
+
*/
|
|
252
|
+
mvcpuLimit: number;
|
|
253
|
+
/**
|
|
254
|
+
* Local storage limit of the container (in bytes).
|
|
255
|
+
*/
|
|
256
|
+
localStorageLimitBytes: number;
|
|
257
|
+
/**
|
|
258
|
+
* Processing time limit for the container.
|
|
259
|
+
*/
|
|
260
|
+
timeout?: string;
|
|
261
|
+
/**
|
|
262
|
+
* Privacy policy of the container.
|
|
263
|
+
*/
|
|
264
|
+
privacy: ContainerPrivacy;
|
|
265
|
+
/**
|
|
266
|
+
* Image reference (e.g. "rg.fr-par.scw.cloud/my-registry-namespace/image:tag").
|
|
267
|
+
*/
|
|
268
|
+
image: string;
|
|
269
|
+
/**
|
|
270
|
+
* Protocol the container uses.
|
|
271
|
+
*/
|
|
272
|
+
protocol: ContainerProtocol;
|
|
273
|
+
/**
|
|
274
|
+
* Port the container listens on.
|
|
275
|
+
*/
|
|
276
|
+
port: number;
|
|
277
|
+
/**
|
|
278
|
+
* If true, it will allow only HTTPS connections to access your container to prevent it from being triggered by insecure connections (HTTP).
|
|
279
|
+
*/
|
|
280
|
+
httpsConnectionsOnly: boolean;
|
|
281
|
+
/**
|
|
282
|
+
* Execution environment of the container.
|
|
283
|
+
*/
|
|
284
|
+
sandbox: ContainerSandbox;
|
|
285
|
+
/**
|
|
286
|
+
* Parameter used to decide when to scale up or down.
|
|
287
|
+
*/
|
|
288
|
+
scalingOption?: ContainerScalingOption;
|
|
289
|
+
/**
|
|
290
|
+
* If the liveness probe fails, the container will be restarted.
|
|
291
|
+
It is performed periodically during the container's lifetime. The liveness probe is not executed until the startup probe (if defined) is successful.
|
|
292
|
+
|
|
293
|
+
Possible check types:
|
|
294
|
+
- http: Perform HTTP check on the container with the specified path.
|
|
295
|
+
- tcp: Perform TCP check on the container.
|
|
296
|
+
*/
|
|
297
|
+
livenessProbe?: ContainerProbe;
|
|
298
|
+
/**
|
|
299
|
+
* If the startup probe fails, the container will be restarted.
|
|
300
|
+
This check is useful for applications that might take a long time to start. It is only performed when the container is starting.
|
|
301
|
+
|
|
302
|
+
Possible check types:
|
|
303
|
+
- http: Perform HTTP check on the container with the specified path.
|
|
304
|
+
- tcp: Perform TCP check on the container.
|
|
305
|
+
*/
|
|
306
|
+
startupProbe?: ContainerProbe;
|
|
307
|
+
/**
|
|
308
|
+
* Tags of the Serverless Container.
|
|
309
|
+
*/
|
|
310
|
+
tags: string[];
|
|
311
|
+
/**
|
|
312
|
+
* When connected to a Private Network, the container can access other Scaleway resources in this Private Network.
|
|
313
|
+
*/
|
|
314
|
+
privateNetworkId?: string;
|
|
315
|
+
/**
|
|
316
|
+
* Command executed when the container starts. This overrides the default command defined in the container image. This is usually the main executable, or ENTRYPOINT script to run.
|
|
317
|
+
*/
|
|
318
|
+
command: string[];
|
|
319
|
+
/**
|
|
320
|
+
* Arguments passed to the command specified in the "command" field. These override the default arguments from the container image, and behave like command-line parameters.
|
|
321
|
+
*/
|
|
322
|
+
args: string[];
|
|
323
|
+
/**
|
|
324
|
+
* This is the default endpoint generated by Scaleway to access the container from the Internet.
|
|
325
|
+
*/
|
|
326
|
+
publicEndpoint: string;
|
|
327
|
+
/**
|
|
328
|
+
* Region in which the container exists.
|
|
329
|
+
*/
|
|
330
|
+
region: ScwRegion;
|
|
331
|
+
}
|
|
332
|
+
export interface Domain {
|
|
333
|
+
/**
|
|
334
|
+
* Domain unique ID.
|
|
335
|
+
*/
|
|
336
|
+
id: string;
|
|
337
|
+
/**
|
|
338
|
+
* Unique ID of the container the domain is assigned to.
|
|
339
|
+
*/
|
|
340
|
+
containerId: string;
|
|
341
|
+
/**
|
|
342
|
+
* Domain assigned to the container.
|
|
343
|
+
*/
|
|
344
|
+
hostname: string;
|
|
345
|
+
/**
|
|
346
|
+
* Domain status.
|
|
347
|
+
*/
|
|
348
|
+
status: DomainStatus;
|
|
349
|
+
/**
|
|
350
|
+
* Domain last error message.
|
|
351
|
+
*/
|
|
352
|
+
errorMessage?: string;
|
|
353
|
+
/**
|
|
354
|
+
* Domain creation date.
|
|
355
|
+
*/
|
|
356
|
+
createdAt?: Date;
|
|
357
|
+
/**
|
|
358
|
+
* Domain last update date.
|
|
359
|
+
*/
|
|
360
|
+
updatedAt?: Date;
|
|
361
|
+
/**
|
|
362
|
+
* A list of arbitrary tags associated with the domain.
|
|
363
|
+
*/
|
|
364
|
+
tags: string[];
|
|
365
|
+
}
|
|
366
|
+
export interface Namespace {
|
|
367
|
+
/**
|
|
368
|
+
* Namespace unique ID.
|
|
369
|
+
*/
|
|
370
|
+
id: string;
|
|
371
|
+
/**
|
|
372
|
+
* Namespace name.
|
|
373
|
+
*/
|
|
374
|
+
name: string;
|
|
375
|
+
/**
|
|
376
|
+
* Unique ID of the Organization the namespace belongs to.
|
|
377
|
+
*/
|
|
378
|
+
organizationId: string;
|
|
379
|
+
/**
|
|
380
|
+
* Unique ID of the Project the namespace belongs to.
|
|
381
|
+
*/
|
|
382
|
+
projectId: string;
|
|
383
|
+
/**
|
|
384
|
+
* Namespace description.
|
|
385
|
+
*/
|
|
386
|
+
description: string;
|
|
387
|
+
/**
|
|
388
|
+
* Namespace status.
|
|
389
|
+
*/
|
|
390
|
+
status: NamespaceStatus;
|
|
391
|
+
/**
|
|
392
|
+
* Namespace last error message.
|
|
393
|
+
*/
|
|
394
|
+
errorMessage?: string;
|
|
395
|
+
/**
|
|
396
|
+
* Namespace environment variables.
|
|
397
|
+
*/
|
|
398
|
+
environmentVariables: Record<string, string>;
|
|
399
|
+
/**
|
|
400
|
+
* Namespace secret environment variables.
|
|
401
|
+
*/
|
|
402
|
+
secretEnvironmentVariables: Record<string, string>;
|
|
403
|
+
/**
|
|
404
|
+
* A list of arbitrary tags associated with the namespace.
|
|
405
|
+
*/
|
|
406
|
+
tags: string[];
|
|
407
|
+
/**
|
|
408
|
+
* Namespace creation date.
|
|
409
|
+
*/
|
|
410
|
+
createdAt?: Date;
|
|
411
|
+
/**
|
|
412
|
+
* Namespace last update date.
|
|
413
|
+
*/
|
|
414
|
+
updatedAt?: Date;
|
|
415
|
+
/**
|
|
416
|
+
* Region in which the namespace will be created.
|
|
417
|
+
*/
|
|
418
|
+
region: ScwRegion;
|
|
419
|
+
}
|
|
420
|
+
export interface Trigger {
|
|
421
|
+
/**
|
|
422
|
+
* Trigger unique ID.
|
|
423
|
+
*/
|
|
424
|
+
id: string;
|
|
425
|
+
/**
|
|
426
|
+
* Name of the trigger.
|
|
427
|
+
*/
|
|
428
|
+
name: string;
|
|
429
|
+
/**
|
|
430
|
+
* Description of the trigger.
|
|
431
|
+
*/
|
|
432
|
+
description: string;
|
|
433
|
+
/**
|
|
434
|
+
* Tags of the trigger.
|
|
435
|
+
*/
|
|
436
|
+
tags: string[];
|
|
437
|
+
/**
|
|
438
|
+
* Trigger status.
|
|
439
|
+
*/
|
|
440
|
+
status: TriggerStatus;
|
|
441
|
+
/**
|
|
442
|
+
* Trigger last error message.
|
|
443
|
+
*/
|
|
444
|
+
errorMessage?: string;
|
|
445
|
+
/**
|
|
446
|
+
* ID of the container to trigger.
|
|
447
|
+
*/
|
|
448
|
+
containerId: string;
|
|
449
|
+
/**
|
|
450
|
+
* Configuration of the destination to trigger.
|
|
451
|
+
*/
|
|
452
|
+
destinationConfig?: TriggerDestinationConfig;
|
|
453
|
+
/**
|
|
454
|
+
* Type of source that will trigger the container.
|
|
455
|
+
*/
|
|
456
|
+
sourceType: TriggerSourceType;
|
|
457
|
+
/**
|
|
458
|
+
* Configuration for a cron source.
|
|
459
|
+
*
|
|
460
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
461
|
+
*/
|
|
462
|
+
cronConfig?: TriggerCronConfig;
|
|
463
|
+
/**
|
|
464
|
+
* Configuration for an SQS queue source.
|
|
465
|
+
*
|
|
466
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
467
|
+
*/
|
|
468
|
+
sqsConfig?: TriggerSQSConfig;
|
|
469
|
+
/**
|
|
470
|
+
* Configuration for a NATS source.
|
|
471
|
+
*
|
|
472
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
473
|
+
*/
|
|
474
|
+
natsConfig?: TriggerNATSConfig;
|
|
475
|
+
/**
|
|
476
|
+
* Trigger creation date.
|
|
477
|
+
*/
|
|
478
|
+
createdAt?: Date;
|
|
479
|
+
/**
|
|
480
|
+
* Trigger last update date.
|
|
481
|
+
*/
|
|
482
|
+
updatedAt?: Date;
|
|
483
|
+
}
|
|
484
|
+
export interface UpdateContainerRequestProbe {
|
|
485
|
+
failureThreshold?: number;
|
|
486
|
+
interval?: string;
|
|
487
|
+
timeout?: string;
|
|
488
|
+
/**
|
|
489
|
+
*
|
|
490
|
+
* One-of ('probe'): at most one of 'http', 'tcp' could be set.
|
|
491
|
+
*/
|
|
492
|
+
http?: UpdateContainerRequestProbeHTTPProbe;
|
|
493
|
+
/**
|
|
494
|
+
*
|
|
495
|
+
* One-of ('probe'): at most one of 'http', 'tcp' could be set.
|
|
496
|
+
*/
|
|
497
|
+
tcp?: UpdateContainerRequestProbeTCPProbe;
|
|
498
|
+
}
|
|
499
|
+
export interface UpdateTriggerRequestCronConfig {
|
|
500
|
+
/**
|
|
501
|
+
* UNIX cron schedule to run job (e.g., "* * * * *").
|
|
502
|
+
*/
|
|
503
|
+
schedule?: string;
|
|
504
|
+
/**
|
|
505
|
+
* Timezone for the cron schedule, in tz database format (e.g., "Europe/Paris").
|
|
506
|
+
*/
|
|
507
|
+
timezone?: string;
|
|
508
|
+
/**
|
|
509
|
+
* Body to send to the container when the trigger is invoked.
|
|
510
|
+
*/
|
|
511
|
+
body?: string;
|
|
512
|
+
/**
|
|
513
|
+
* Additional headers to send to the container when the trigger is invoked.
|
|
514
|
+
*/
|
|
515
|
+
headers?: Record<string, string>;
|
|
516
|
+
}
|
|
517
|
+
export interface UpdateTriggerRequestDestinationConfig {
|
|
518
|
+
/**
|
|
519
|
+
* The HTTP path to send the request to (e.g., "/my-webhook-endpoint").
|
|
520
|
+
*/
|
|
521
|
+
httpPath?: string;
|
|
522
|
+
/**
|
|
523
|
+
* The HTTP method to use when sending the request (e.g., get, post, put, patch, delete). Must be specified as lowercase.
|
|
524
|
+
*/
|
|
525
|
+
httpMethod?: UpdateTriggerRequestDestinationConfigHttpMethod;
|
|
526
|
+
}
|
|
527
|
+
export interface UpdateTriggerRequestNATSConfig {
|
|
528
|
+
/**
|
|
529
|
+
* The URLs of the NATS server (e.g., "nats://nats.mnq.fr-par.scaleway.com:4222").
|
|
530
|
+
*/
|
|
531
|
+
serverUrls?: string[];
|
|
532
|
+
/**
|
|
533
|
+
* NATS subject to subscribe to (e.g., "my-subject").
|
|
534
|
+
*/
|
|
535
|
+
subject?: string;
|
|
536
|
+
/**
|
|
537
|
+
* The credentials from this file will be used to authenticate with the NATS server and subscribe to the specified subject.
|
|
538
|
+
*/
|
|
539
|
+
credentialsFileContent?: string;
|
|
540
|
+
}
|
|
541
|
+
export interface UpdateTriggerRequestSQSConfig {
|
|
542
|
+
/**
|
|
543
|
+
* The region where the SQS queue is hosted (e.g., "fr-par", "nl-ams").
|
|
544
|
+
*/
|
|
545
|
+
region?: ScwRegion;
|
|
546
|
+
/**
|
|
547
|
+
* Endpoint URL to use to access SQS (e.g., "https://sqs.mnq.fr-par.scaleway.com").
|
|
548
|
+
*/
|
|
549
|
+
endpoint?: string;
|
|
550
|
+
/**
|
|
551
|
+
* The access key for accessing the SQS queue.
|
|
552
|
+
*/
|
|
553
|
+
accessKeyId?: string;
|
|
554
|
+
/**
|
|
555
|
+
* The secret key for accessing the SQS queue.
|
|
556
|
+
*/
|
|
557
|
+
secretAccessKey?: string;
|
|
558
|
+
/**
|
|
559
|
+
* The URL of the SQS queue to monitor for messages.
|
|
560
|
+
*/
|
|
561
|
+
queueUrl?: string;
|
|
562
|
+
}
|
|
563
|
+
export type CreateContainerRequest = {
|
|
564
|
+
/**
|
|
565
|
+
* Region to target. If none is passed will use default region from the config.
|
|
566
|
+
*/
|
|
567
|
+
region?: ScwRegion;
|
|
568
|
+
/**
|
|
569
|
+
* Unique ID of the namespace the container belongs to.
|
|
570
|
+
*/
|
|
571
|
+
namespaceId: string;
|
|
572
|
+
/**
|
|
573
|
+
* Container name.
|
|
574
|
+
*/
|
|
575
|
+
name: string;
|
|
576
|
+
/**
|
|
577
|
+
* Environment variables of the container.
|
|
578
|
+
*/
|
|
579
|
+
environmentVariables?: Record<string, string>;
|
|
580
|
+
/**
|
|
581
|
+
* Secret environment variables of the container.
|
|
582
|
+
*/
|
|
583
|
+
secretEnvironmentVariables?: Record<string, string>;
|
|
584
|
+
/**
|
|
585
|
+
* Minimum number of instances to scale the container to.
|
|
586
|
+
*/
|
|
587
|
+
minScale?: number;
|
|
588
|
+
/**
|
|
589
|
+
* Maximum number of instances to scale the container to.
|
|
590
|
+
*/
|
|
591
|
+
maxScale?: number;
|
|
592
|
+
/**
|
|
593
|
+
* Memory limit of the container in bytes.
|
|
594
|
+
*/
|
|
595
|
+
memoryLimitBytes?: number;
|
|
596
|
+
/**
|
|
597
|
+
* CPU limit of the container in mvCPU.
|
|
598
|
+
*/
|
|
599
|
+
mvcpuLimit?: number;
|
|
600
|
+
/**
|
|
601
|
+
* Processing time limit for the container.
|
|
602
|
+
*/
|
|
603
|
+
timeout?: string;
|
|
604
|
+
/**
|
|
605
|
+
* Privacy policy of the container.
|
|
606
|
+
*/
|
|
607
|
+
privacy?: ContainerPrivacy;
|
|
608
|
+
/**
|
|
609
|
+
* Container description.
|
|
610
|
+
*/
|
|
611
|
+
description?: string;
|
|
612
|
+
/**
|
|
613
|
+
* Image reference (e.g. "rg.fr-par.scw.cloud/my-registry-namespace/image:tag").
|
|
614
|
+
*/
|
|
615
|
+
image: string;
|
|
616
|
+
/**
|
|
617
|
+
* Protocol the container uses.
|
|
618
|
+
*/
|
|
619
|
+
protocol?: ContainerProtocol;
|
|
620
|
+
/**
|
|
621
|
+
* Port the container listens on.
|
|
622
|
+
*/
|
|
623
|
+
port?: number;
|
|
624
|
+
/**
|
|
625
|
+
* If true, it will allow only HTTPS connections to access your container to prevent it from being triggered by insecure connections (HTTP).
|
|
626
|
+
*/
|
|
627
|
+
httpsConnectionsOnly?: boolean;
|
|
628
|
+
/**
|
|
629
|
+
* Execution environment of the container.
|
|
630
|
+
*/
|
|
631
|
+
sandbox?: ContainerSandbox;
|
|
632
|
+
/**
|
|
633
|
+
* Local storage limit of the container (in bytes).
|
|
634
|
+
*/
|
|
635
|
+
localStorageLimitBytes?: number;
|
|
636
|
+
/**
|
|
637
|
+
* Parameter used to decide when to scale up or down.
|
|
638
|
+
*/
|
|
639
|
+
scalingOption?: ContainerScalingOption;
|
|
640
|
+
/**
|
|
641
|
+
* If the liveness probe fails, the container will be restarted.
|
|
642
|
+
It is performed periodically during the container's lifetime. The liveness probe is not executed until the startup probe (if defined) is successful.
|
|
643
|
+
|
|
644
|
+
Possible check types:
|
|
645
|
+
- http: Perform HTTP check on the container with the specified path.
|
|
646
|
+
- tcp: Perform TCP check on the container.
|
|
647
|
+
*/
|
|
648
|
+
livenessProbe?: ContainerProbe;
|
|
649
|
+
/**
|
|
650
|
+
* If the startup probe fails, the container will be restarted.
|
|
651
|
+
This check is useful for applications that might take a long time to start. It is only performed when the container is starting.
|
|
652
|
+
|
|
653
|
+
Possible check types:
|
|
654
|
+
- http: Perform HTTP check on the container with the specified path.
|
|
655
|
+
- tcp: Perform TCP check on the container.
|
|
656
|
+
*/
|
|
657
|
+
startupProbe?: ContainerProbe;
|
|
658
|
+
/**
|
|
659
|
+
* Tags of the Serverless Container.
|
|
660
|
+
*/
|
|
661
|
+
tags?: string[];
|
|
662
|
+
/**
|
|
663
|
+
* When connected to a Private Network, the container can access other Scaleway resources in this Private Network.
|
|
664
|
+
*/
|
|
665
|
+
privateNetworkId?: string;
|
|
666
|
+
/**
|
|
667
|
+
* Command executed when the container starts. This overrides the default command defined in the container image. This is usually the main executable, or ENTRYPOINT script to run.
|
|
668
|
+
*/
|
|
669
|
+
command?: string[];
|
|
670
|
+
/**
|
|
671
|
+
* Arguments passed to the command specified in the "command" field. These override the default arguments from the container image, and behave like command-line parameters.
|
|
672
|
+
*/
|
|
673
|
+
args?: string[];
|
|
674
|
+
};
|
|
675
|
+
export type CreateDomainRequest = {
|
|
676
|
+
/**
|
|
677
|
+
* Region to target. If none is passed will use default region from the config.
|
|
678
|
+
*/
|
|
679
|
+
region?: ScwRegion;
|
|
680
|
+
/**
|
|
681
|
+
* Unique ID of the container the domain will be assigned to.
|
|
682
|
+
*/
|
|
683
|
+
containerId: string;
|
|
684
|
+
/**
|
|
685
|
+
* Domain assigned to the container.
|
|
686
|
+
*/
|
|
687
|
+
hostname: string;
|
|
688
|
+
/**
|
|
689
|
+
* A list of arbitrary tags associated with the domain.
|
|
690
|
+
*/
|
|
691
|
+
tags?: string[];
|
|
692
|
+
};
|
|
693
|
+
export type CreateNamespaceRequest = {
|
|
694
|
+
/**
|
|
695
|
+
* Region to target. If none is passed will use default region from the config.
|
|
696
|
+
*/
|
|
697
|
+
region?: ScwRegion;
|
|
698
|
+
/**
|
|
699
|
+
* Unique ID of the Project the namespace belongs to.
|
|
700
|
+
*/
|
|
701
|
+
projectId?: string;
|
|
702
|
+
/**
|
|
703
|
+
* Namespace name.
|
|
704
|
+
*/
|
|
705
|
+
name: string;
|
|
706
|
+
/**
|
|
707
|
+
* Namespace description.
|
|
708
|
+
*/
|
|
709
|
+
description?: string;
|
|
710
|
+
/**
|
|
711
|
+
* Namespace environment variables.
|
|
712
|
+
*/
|
|
713
|
+
environmentVariables?: Record<string, string>;
|
|
714
|
+
/**
|
|
715
|
+
* Namespace secret environment variables.
|
|
716
|
+
*/
|
|
717
|
+
secretEnvironmentVariables?: Record<string, string>;
|
|
718
|
+
/**
|
|
719
|
+
* A list of arbitrary tags associated with the namespace.
|
|
720
|
+
*/
|
|
721
|
+
tags?: string[];
|
|
722
|
+
};
|
|
723
|
+
export type CreateTriggerRequest = {
|
|
724
|
+
/**
|
|
725
|
+
* Region to target. If none is passed will use default region from the config.
|
|
726
|
+
*/
|
|
727
|
+
region?: ScwRegion;
|
|
728
|
+
/**
|
|
729
|
+
* ID of the container to trigger.
|
|
730
|
+
*/
|
|
731
|
+
containerId: string;
|
|
732
|
+
/**
|
|
733
|
+
* Name of the trigger.
|
|
734
|
+
*/
|
|
735
|
+
name: string;
|
|
736
|
+
/**
|
|
737
|
+
* Description of the trigger.
|
|
738
|
+
*/
|
|
739
|
+
description?: string;
|
|
740
|
+
/**
|
|
741
|
+
* Tags of the trigger.
|
|
742
|
+
*/
|
|
743
|
+
tags?: string[];
|
|
744
|
+
/**
|
|
745
|
+
* Configuration of the destination to trigger.
|
|
746
|
+
*/
|
|
747
|
+
destinationConfig?: CreateTriggerRequestDestinationConfig;
|
|
748
|
+
/**
|
|
749
|
+
* Configuration for a cron source.
|
|
750
|
+
*
|
|
751
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
752
|
+
*/
|
|
753
|
+
cronConfig?: CreateTriggerRequestCronConfig;
|
|
754
|
+
/**
|
|
755
|
+
* Configuration for an SQS queue source.
|
|
756
|
+
*
|
|
757
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
758
|
+
*/
|
|
759
|
+
sqsConfig?: CreateTriggerRequestSQSConfig;
|
|
760
|
+
/**
|
|
761
|
+
* Configuration for a NATS source.
|
|
762
|
+
*
|
|
763
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
764
|
+
*/
|
|
765
|
+
natsConfig?: CreateTriggerRequestNATSConfig;
|
|
766
|
+
};
|
|
767
|
+
export type DeleteContainerRequest = {
|
|
768
|
+
/**
|
|
769
|
+
* Region to target. If none is passed will use default region from the config.
|
|
770
|
+
*/
|
|
771
|
+
region?: ScwRegion;
|
|
772
|
+
/**
|
|
773
|
+
* UUID of the container to delete.
|
|
774
|
+
*/
|
|
775
|
+
containerId: string;
|
|
776
|
+
};
|
|
777
|
+
export type DeleteDomainRequest = {
|
|
778
|
+
/**
|
|
779
|
+
* Region to target. If none is passed will use default region from the config.
|
|
780
|
+
*/
|
|
781
|
+
region?: ScwRegion;
|
|
782
|
+
/**
|
|
783
|
+
* UUID of the domain to delete.
|
|
784
|
+
*/
|
|
785
|
+
domainId: string;
|
|
786
|
+
};
|
|
787
|
+
export type DeleteNamespaceRequest = {
|
|
788
|
+
/**
|
|
789
|
+
* Region to target. If none is passed will use default region from the config.
|
|
790
|
+
*/
|
|
791
|
+
region?: ScwRegion;
|
|
792
|
+
/**
|
|
793
|
+
* UUID of the namespace to delete.
|
|
794
|
+
*/
|
|
795
|
+
namespaceId: string;
|
|
796
|
+
};
|
|
797
|
+
export type DeleteTriggerRequest = {
|
|
798
|
+
/**
|
|
799
|
+
* Region to target. If none is passed will use default region from the config.
|
|
800
|
+
*/
|
|
801
|
+
region?: ScwRegion;
|
|
802
|
+
/**
|
|
803
|
+
* ID of the trigger to delete.
|
|
804
|
+
*/
|
|
805
|
+
triggerId: string;
|
|
806
|
+
};
|
|
807
|
+
export type GetContainerRequest = {
|
|
808
|
+
/**
|
|
809
|
+
* Region to target. If none is passed will use default region from the config.
|
|
810
|
+
*/
|
|
811
|
+
region?: ScwRegion;
|
|
812
|
+
containerId: string;
|
|
813
|
+
};
|
|
814
|
+
export type GetDomainRequest = {
|
|
815
|
+
/**
|
|
816
|
+
* Region to target. If none is passed will use default region from the config.
|
|
817
|
+
*/
|
|
818
|
+
region?: ScwRegion;
|
|
819
|
+
domainId: string;
|
|
820
|
+
};
|
|
821
|
+
export type GetNamespaceRequest = {
|
|
822
|
+
/**
|
|
823
|
+
* Region to target. If none is passed will use default region from the config.
|
|
824
|
+
*/
|
|
825
|
+
region?: ScwRegion;
|
|
826
|
+
namespaceId: string;
|
|
827
|
+
};
|
|
828
|
+
export type GetServiceInfoRequest = {
|
|
829
|
+
/**
|
|
830
|
+
* Region to target. If none is passed will use default region from the config.
|
|
831
|
+
*/
|
|
832
|
+
region?: ScwRegion;
|
|
833
|
+
};
|
|
834
|
+
export type GetTriggerRequest = {
|
|
835
|
+
/**
|
|
836
|
+
* Region to target. If none is passed will use default region from the config.
|
|
837
|
+
*/
|
|
838
|
+
region?: ScwRegion;
|
|
839
|
+
triggerId: string;
|
|
840
|
+
};
|
|
841
|
+
export type ListContainersRequest = {
|
|
842
|
+
/**
|
|
843
|
+
* Region to target. If none is passed will use default region from the config.
|
|
844
|
+
*/
|
|
845
|
+
region?: ScwRegion;
|
|
846
|
+
page?: number;
|
|
847
|
+
pageSize?: number;
|
|
848
|
+
orderBy?: ListContainersRequestOrderBy;
|
|
849
|
+
organizationId?: string;
|
|
850
|
+
projectId?: string;
|
|
851
|
+
namespaceId?: string;
|
|
852
|
+
name?: string;
|
|
853
|
+
};
|
|
854
|
+
export interface ListContainersResponse {
|
|
855
|
+
containers: Container[];
|
|
856
|
+
totalCount: number;
|
|
857
|
+
}
|
|
858
|
+
export type ListDomainsRequest = {
|
|
859
|
+
/**
|
|
860
|
+
* Region to target. If none is passed will use default region from the config.
|
|
861
|
+
*/
|
|
862
|
+
region?: ScwRegion;
|
|
863
|
+
page?: number;
|
|
864
|
+
pageSize?: number;
|
|
865
|
+
orderBy?: ListDomainsRequestOrderBy;
|
|
866
|
+
organizationId?: string;
|
|
867
|
+
projectId?: string;
|
|
868
|
+
namespaceId?: string;
|
|
869
|
+
containerId?: string;
|
|
870
|
+
};
|
|
871
|
+
export interface ListDomainsResponse {
|
|
872
|
+
domains: Domain[];
|
|
873
|
+
totalCount: number;
|
|
874
|
+
}
|
|
875
|
+
export type ListNamespacesRequest = {
|
|
876
|
+
/**
|
|
877
|
+
* Region to target. If none is passed will use default region from the config.
|
|
878
|
+
*/
|
|
879
|
+
region?: ScwRegion;
|
|
880
|
+
page?: number;
|
|
881
|
+
pageSize?: number;
|
|
882
|
+
orderBy?: ListNamespacesRequestOrderBy;
|
|
883
|
+
organizationId?: string;
|
|
884
|
+
projectId?: string;
|
|
885
|
+
name?: string;
|
|
886
|
+
};
|
|
887
|
+
export interface ListNamespacesResponse {
|
|
888
|
+
namespaces: Namespace[];
|
|
889
|
+
totalCount: number;
|
|
890
|
+
}
|
|
891
|
+
export type ListTriggersRequest = {
|
|
892
|
+
/**
|
|
893
|
+
* Region to target. If none is passed will use default region from the config.
|
|
894
|
+
*/
|
|
895
|
+
region?: ScwRegion;
|
|
896
|
+
page?: number;
|
|
897
|
+
pageSize?: number;
|
|
898
|
+
orderBy?: ListTriggersRequestOrderBy;
|
|
899
|
+
organizationId?: string;
|
|
900
|
+
projectId?: string;
|
|
901
|
+
namespaceId?: string;
|
|
902
|
+
containerId?: string;
|
|
903
|
+
};
|
|
904
|
+
export interface ListTriggersResponse {
|
|
905
|
+
triggers: Trigger[];
|
|
906
|
+
totalCount: number;
|
|
907
|
+
}
|
|
908
|
+
export type RedeployContainerRequest = {
|
|
909
|
+
/**
|
|
910
|
+
* Region to target. If none is passed will use default region from the config.
|
|
911
|
+
*/
|
|
912
|
+
region?: ScwRegion;
|
|
913
|
+
/**
|
|
914
|
+
* ID of the container to redeploy.
|
|
915
|
+
*/
|
|
916
|
+
containerId: string;
|
|
917
|
+
};
|
|
918
|
+
export type UpdateContainerRequest = {
|
|
919
|
+
/**
|
|
920
|
+
* Region to target. If none is passed will use default region from the config.
|
|
921
|
+
*/
|
|
922
|
+
region?: ScwRegion;
|
|
923
|
+
/**
|
|
924
|
+
* UUID of the container to update.
|
|
925
|
+
*/
|
|
926
|
+
containerId: string;
|
|
927
|
+
/**
|
|
928
|
+
* Environment variables of the container.
|
|
929
|
+
*/
|
|
930
|
+
environmentVariables?: Record<string, string>;
|
|
931
|
+
/**
|
|
932
|
+
* Secret environment variables of the container.
|
|
933
|
+
*/
|
|
934
|
+
secretEnvironmentVariables?: Record<string, string>;
|
|
935
|
+
/**
|
|
936
|
+
* Minimum number of instances to scale the container to.
|
|
937
|
+
*/
|
|
938
|
+
minScale?: number;
|
|
939
|
+
/**
|
|
940
|
+
* Maximum number of instances to scale the container to.
|
|
941
|
+
*/
|
|
942
|
+
maxScale?: number;
|
|
943
|
+
/**
|
|
944
|
+
* Memory limit of the container in bytes.
|
|
945
|
+
*/
|
|
946
|
+
memoryLimitBytes?: number;
|
|
947
|
+
/**
|
|
948
|
+
* CPU limit of the container in mvCPU.
|
|
949
|
+
*/
|
|
950
|
+
mvcpuLimit?: number;
|
|
951
|
+
/**
|
|
952
|
+
* Processing time limit for the container.
|
|
953
|
+
*/
|
|
954
|
+
timeout?: string;
|
|
955
|
+
/**
|
|
956
|
+
* Privacy policy of the container.
|
|
957
|
+
*/
|
|
958
|
+
privacy?: ContainerPrivacy;
|
|
959
|
+
/**
|
|
960
|
+
* Container description.
|
|
961
|
+
*/
|
|
962
|
+
description?: string;
|
|
963
|
+
/**
|
|
964
|
+
* Image reference (e.g. "rg.fr-par.scw.cloud/my-registry-namespace/image:tag").
|
|
965
|
+
*/
|
|
966
|
+
image?: string;
|
|
967
|
+
/**
|
|
968
|
+
* Protocol the container uses.
|
|
969
|
+
*/
|
|
970
|
+
protocol?: ContainerProtocol;
|
|
971
|
+
/**
|
|
972
|
+
* Port the container listens on.
|
|
973
|
+
*/
|
|
974
|
+
port?: number;
|
|
975
|
+
/**
|
|
976
|
+
* If true, it will allow only HTTPS connections to access your container to prevent it from being triggered by insecure connections (HTTP).
|
|
977
|
+
*/
|
|
978
|
+
httpsConnectionOnly?: boolean;
|
|
979
|
+
/**
|
|
980
|
+
* Execution environment of the container.
|
|
981
|
+
*/
|
|
982
|
+
sandbox?: ContainerSandbox;
|
|
983
|
+
/**
|
|
984
|
+
* Local storage limit of the container (in bytes).
|
|
985
|
+
*/
|
|
986
|
+
localStorageLimitBytes?: number;
|
|
987
|
+
/**
|
|
988
|
+
* Parameter used to decide when to scale up or down.
|
|
989
|
+
*/
|
|
990
|
+
scalingOption?: ContainerScalingOption;
|
|
991
|
+
/**
|
|
992
|
+
* If the liveness probe fails, the container will be restarted.
|
|
993
|
+
It is performed periodically during the container's lifetime. The liveness probe is not executed until the startup probe (if defined) is successful.
|
|
994
|
+
|
|
995
|
+
Possible check types:
|
|
996
|
+
- http: Perform HTTP check on the container with the specified path.
|
|
997
|
+
- tcp: Perform TCP check on the container.
|
|
998
|
+
*/
|
|
999
|
+
livenessProbe?: ContainerProbe;
|
|
1000
|
+
/**
|
|
1001
|
+
* If the startup probe fails, the container will be restarted.
|
|
1002
|
+
This check is useful for applications that might take a long time to start. It is only performed when the container is starting.
|
|
1003
|
+
|
|
1004
|
+
Possible check types:
|
|
1005
|
+
- http: Perform HTTP check on the container with the specified path.
|
|
1006
|
+
- tcp: Perform TCP check on the container.
|
|
1007
|
+
*/
|
|
1008
|
+
startupProbe?: UpdateContainerRequestProbe;
|
|
1009
|
+
/**
|
|
1010
|
+
* Tags of the Serverless Container.
|
|
1011
|
+
*/
|
|
1012
|
+
tags?: string[];
|
|
1013
|
+
/**
|
|
1014
|
+
* When connected to a Private Network, the container can access other Scaleway resources in this Private Network.
|
|
1015
|
+
*/
|
|
1016
|
+
privateNetworkId?: string;
|
|
1017
|
+
/**
|
|
1018
|
+
* Command executed when the container starts. This overrides the default command defined in the container image. This is usually the main executable, or ENTRYPOINT script to run.
|
|
1019
|
+
*/
|
|
1020
|
+
command?: string[];
|
|
1021
|
+
/**
|
|
1022
|
+
* Arguments passed to the command specified in the "command" field. These override the default arguments from the container image, and behave like command-line parameters.
|
|
1023
|
+
*/
|
|
1024
|
+
args?: string[];
|
|
1025
|
+
};
|
|
1026
|
+
export type UpdateDomainRequest = {
|
|
1027
|
+
/**
|
|
1028
|
+
* Region to target. If none is passed will use default region from the config.
|
|
1029
|
+
*/
|
|
1030
|
+
region?: ScwRegion;
|
|
1031
|
+
/**
|
|
1032
|
+
* UUID of the domain to update.
|
|
1033
|
+
*/
|
|
1034
|
+
domainId: string;
|
|
1035
|
+
/**
|
|
1036
|
+
* A list of arbitrary tags associated with the domain.
|
|
1037
|
+
*/
|
|
1038
|
+
tags?: string[];
|
|
1039
|
+
};
|
|
1040
|
+
export type UpdateNamespaceRequest = {
|
|
1041
|
+
/**
|
|
1042
|
+
* Region to target. If none is passed will use default region from the config.
|
|
1043
|
+
*/
|
|
1044
|
+
region?: ScwRegion;
|
|
1045
|
+
/**
|
|
1046
|
+
* UUID of the namespace to update.
|
|
1047
|
+
*/
|
|
1048
|
+
namespaceId: string;
|
|
1049
|
+
/**
|
|
1050
|
+
* Namespace description.
|
|
1051
|
+
*/
|
|
1052
|
+
description?: string;
|
|
1053
|
+
/**
|
|
1054
|
+
* Namespace environment variables.
|
|
1055
|
+
*/
|
|
1056
|
+
environmentVariables?: Record<string, string>;
|
|
1057
|
+
/**
|
|
1058
|
+
* Namespace secret environment variables.
|
|
1059
|
+
*/
|
|
1060
|
+
secretEnvironmentVariables?: Record<string, string>;
|
|
1061
|
+
/**
|
|
1062
|
+
* A list of arbitrary tags associated with the namespace.
|
|
1063
|
+
*/
|
|
1064
|
+
tags?: string[];
|
|
1065
|
+
};
|
|
1066
|
+
export type UpdateTriggerRequest = {
|
|
1067
|
+
/**
|
|
1068
|
+
* Region to target. If none is passed will use default region from the config.
|
|
1069
|
+
*/
|
|
1070
|
+
region?: ScwRegion;
|
|
1071
|
+
/**
|
|
1072
|
+
* ID of the trigger to update.
|
|
1073
|
+
*/
|
|
1074
|
+
triggerId: string;
|
|
1075
|
+
/**
|
|
1076
|
+
* Name of the trigger.
|
|
1077
|
+
*/
|
|
1078
|
+
name?: string;
|
|
1079
|
+
/**
|
|
1080
|
+
* Description of the trigger.
|
|
1081
|
+
*/
|
|
1082
|
+
description?: string;
|
|
1083
|
+
/**
|
|
1084
|
+
* Tags of the trigger.
|
|
1085
|
+
*/
|
|
1086
|
+
tags?: string[];
|
|
1087
|
+
/**
|
|
1088
|
+
* Configuration of the destination to trigger.
|
|
1089
|
+
*/
|
|
1090
|
+
destinationConfig?: UpdateTriggerRequestDestinationConfig;
|
|
1091
|
+
/**
|
|
1092
|
+
* Configuration for a cron source.
|
|
1093
|
+
*
|
|
1094
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
1095
|
+
*/
|
|
1096
|
+
cronConfig?: UpdateTriggerRequestCronConfig;
|
|
1097
|
+
/**
|
|
1098
|
+
* Configuration for an SQS queue source.
|
|
1099
|
+
*
|
|
1100
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
1101
|
+
*/
|
|
1102
|
+
sqsConfig?: UpdateTriggerRequestSQSConfig;
|
|
1103
|
+
/**
|
|
1104
|
+
* Configuration for a NATS source.
|
|
1105
|
+
*
|
|
1106
|
+
* One-of ('sourceConfig'): at most one of 'cronConfig', 'sqsConfig', 'natsConfig' could be set.
|
|
1107
|
+
*/
|
|
1108
|
+
natsConfig?: UpdateTriggerRequestNATSConfig;
|
|
1109
|
+
};
|