@highstate/k8s 0.7.2 → 0.7.3
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/{helm-wPTgVV1N.js → chunk-K4WKJ4L5.js} +89 -47
- package/dist/chunk-K4WKJ4L5.js.map +1 -0
- package/dist/{shared-Clzbl5K-.js → chunk-T5Z2M4JE.js} +21 -7
- package/dist/chunk-T5Z2M4JE.js.map +1 -0
- package/dist/highstate.manifest.json +9 -0
- package/dist/index.js +304 -154
- package/dist/index.js.map +1 -0
- package/dist/units/access-point/index.js +9 -7
- package/dist/units/access-point/index.js.map +1 -0
- package/dist/units/cert-manager/index.js +29 -29
- package/dist/units/cert-manager/index.js.map +1 -0
- package/dist/units/dns01-issuer/index.js +22 -14
- package/dist/units/dns01-issuer/index.js.map +1 -0
- package/dist/units/existing-cluster/index.js +49 -21
- package/dist/units/existing-cluster/index.js.map +1 -0
- package/package.json +15 -16
- package/src/access-point.ts +185 -0
- package/src/container.ts +271 -0
- package/src/cron-job.ts +77 -0
- package/src/deployment.ts +210 -0
- package/src/gateway/backend.ts +61 -0
- package/src/gateway/http-route.ts +139 -0
- package/src/gateway/index.ts +2 -0
- package/src/helm.ts +298 -0
- package/src/index.ts +61 -0
- package/src/job.ts +66 -0
- package/src/network-policy.ts +732 -0
- package/src/pod.ts +5 -0
- package/src/pvc.ts +178 -0
- package/src/scripting/bundle.ts +244 -0
- package/src/scripting/container.ts +44 -0
- package/src/scripting/environment.ts +79 -0
- package/src/scripting/index.ts +3 -0
- package/src/service.ts +279 -0
- package/src/shared.ts +150 -0
- package/src/stateful-set.ts +159 -0
- package/src/units/access-point/index.ts +12 -0
- package/src/units/cert-manager/index.ts +37 -0
- package/src/units/dns01-issuer/index.ts +41 -0
- package/src/units/dns01-issuer/solver.ts +23 -0
- package/src/units/existing-cluster/index.ts +107 -0
- package/src/workload.ts +150 -0
- package/assets/charts.json +0 -8
- package/dist/index.d.ts +0 -1036
package/dist/index.d.ts
DELETED
@@ -1,1036 +0,0 @@
|
|
1
|
-
import { PartialKeys, RequiredKeys } from '@highstate/contract';
|
2
|
-
import { k8s } from '@highstate/library';
|
3
|
-
import { Input, Unwrap, Output, ComponentResource, InputArray, Resource, Inputs, ComponentResourceOptions, ResourceOptions, InputMap } from '@highstate/pulumi';
|
4
|
-
import { Provider, core, types, batch, helm } from '@pulumi/kubernetes';
|
5
|
-
import { gateway, types as types$1 } from '@highstate/gateway-api';
|
6
|
-
import { Input as Input$1, ComponentResource as ComponentResource$1, Output as Output$1, ComponentResourceOptions as ComponentResourceOptions$1 } from '@pulumi/pulumi';
|
7
|
-
import { DnsRecord } from '@highstate/common';
|
8
|
-
import { local } from '@pulumi/command';
|
9
|
-
|
10
|
-
declare function getProvider(cluster: Input<k8s.Cluster>): Promise<Provider>;
|
11
|
-
declare function createNamespace(name: string, provider: Provider, args?: core.v1.NamespaceArgs): core.v1.Namespace;
|
12
|
-
declare function getNamespace(name: string | undefined, provider: Provider): core.v1.Namespace;
|
13
|
-
type NamespaceLike = core.v1.Namespace | string;
|
14
|
-
type CommonArgs = {
|
15
|
-
/**
|
16
|
-
* The name of the resource.
|
17
|
-
*/
|
18
|
-
name?: string;
|
19
|
-
/**
|
20
|
-
* The namespace to create the resource in.
|
21
|
-
*/
|
22
|
-
namespace: Input<NamespaceLike | undefined>;
|
23
|
-
/**
|
24
|
-
* The metadata to apply to the resource.
|
25
|
-
*/
|
26
|
-
metadata?: Input<types.input.meta.v1.ObjectMeta>;
|
27
|
-
};
|
28
|
-
declare function mapMetadata(args: PartialKeys<Unwrap<CommonArgs>, "namespace">, fallbackName?: string): types.input.meta.v1.ObjectMeta;
|
29
|
-
type SelectorLike = types.input.meta.v1.LabelSelector | Record<string, Input<string>>;
|
30
|
-
declare function mapSelectorLikeToSelector(selector: SelectorLike): types.input.meta.v1.LabelSelector;
|
31
|
-
declare function mapNamespaceLikeToNamespaceName(namespace: NamespaceLike): Output<string>;
|
32
|
-
declare function mapNamespaceNameToSelector(namespace: Input<string>): types.input.meta.v1.LabelSelector;
|
33
|
-
type ResourceId = {
|
34
|
-
name: Input<string>;
|
35
|
-
namespace?: Input<string | undefined>;
|
36
|
-
};
|
37
|
-
declare function getAppName(resourceId: Unwrap<ResourceId>): string;
|
38
|
-
declare function getAppDisplayName(resourceId: Unwrap<ResourceId>): string;
|
39
|
-
|
40
|
-
type ServiceArgs = CommonArgs & {
|
41
|
-
port?: Input<types.input.core.v1.ServicePort>;
|
42
|
-
/**
|
43
|
-
* The service to patch instead of creating a new one.
|
44
|
-
*/
|
45
|
-
patch?: Input<k8s.Service>;
|
46
|
-
/**
|
47
|
-
* The cluster to create the resource in.
|
48
|
-
*/
|
49
|
-
cluster: Input<k8s.Cluster>;
|
50
|
-
} & types.input.core.v1.ServiceSpec;
|
51
|
-
declare abstract class Service extends ComponentResource {
|
52
|
-
/**
|
53
|
-
* The cluster info associated with the service.
|
54
|
-
*/
|
55
|
-
readonly clusterInfo: Output<k8s.ClusterInfo>;
|
56
|
-
/**
|
57
|
-
* The metadata of the underlying Kubernetes service.
|
58
|
-
*/
|
59
|
-
readonly metadata: Output<types.output.meta.v1.ObjectMeta>;
|
60
|
-
/**
|
61
|
-
* The spec of the underlying Kubernetes service.
|
62
|
-
*/
|
63
|
-
readonly spec: Output<types.output.core.v1.ServiceSpec>;
|
64
|
-
/**
|
65
|
-
* The status of the underlying Kubernetes service.
|
66
|
-
*/
|
67
|
-
readonly status: Output<types.output.core.v1.ServiceStatus>;
|
68
|
-
/**
|
69
|
-
* The resources associated with the service.
|
70
|
-
*/
|
71
|
-
readonly resources: InputArray<Resource>;
|
72
|
-
protected constructor(type: string, name: string, args: Inputs, opts: ComponentResourceOptions,
|
73
|
-
/**
|
74
|
-
* The cluster info associated with the service.
|
75
|
-
*/
|
76
|
-
clusterInfo: Output<k8s.ClusterInfo>,
|
77
|
-
/**
|
78
|
-
* The metadata of the underlying Kubernetes service.
|
79
|
-
*/
|
80
|
-
metadata: Output<types.output.meta.v1.ObjectMeta>,
|
81
|
-
/**
|
82
|
-
* The spec of the underlying Kubernetes service.
|
83
|
-
*/
|
84
|
-
spec: Output<types.output.core.v1.ServiceSpec>,
|
85
|
-
/**
|
86
|
-
* The status of the underlying Kubernetes service.
|
87
|
-
*/
|
88
|
-
status: Output<types.output.core.v1.ServiceStatus>,
|
89
|
-
/**
|
90
|
-
* The resources associated with the service.
|
91
|
-
*/
|
92
|
-
resources: InputArray<Resource>);
|
93
|
-
/**
|
94
|
-
* The Highstate service entity.
|
95
|
-
*/
|
96
|
-
get entity(): Output<k8s.Service>;
|
97
|
-
static create(name: string, args: ServiceArgs, opts: ComponentResourceOptions): Service;
|
98
|
-
static wrap(name: string, service: Input<core.v1.Service>, clusterInfo: Input<k8s.ClusterInfo>, opts: ComponentResourceOptions): Service;
|
99
|
-
static external(name: string, id: ResourceId, clusterInfo: Input<k8s.ClusterInfo>, opts: ComponentResourceOptions): Service;
|
100
|
-
static of(name: string, entity: Input<k8s.Service>, opts: ComponentResourceOptions): Service;
|
101
|
-
/**
|
102
|
-
* Returns the host of the service accessible from the cluster.
|
103
|
-
*
|
104
|
-
* The format is `name.namespace.svc`.
|
105
|
-
*/
|
106
|
-
get clusterHost(): Output<string>;
|
107
|
-
/**
|
108
|
-
* Returns the external IP of the service.
|
109
|
-
*
|
110
|
-
* If the load balancer is available, the external IP is returned, otherwise the IP of the node.
|
111
|
-
*
|
112
|
-
* If the service has no external IP, `undefined` is returned.
|
113
|
-
*/
|
114
|
-
get externalIp(): Output<string | undefined>;
|
115
|
-
/**
|
116
|
-
* The "most public" IP of the service.
|
117
|
-
*
|
118
|
-
* Resolves to the external IP if available, otherwise the cluster IP.
|
119
|
-
*
|
120
|
-
* If the service is headless, an error is thrown.
|
121
|
-
*/
|
122
|
-
get ip(): Output<string>;
|
123
|
-
}
|
124
|
-
declare function mapContainerPortToServicePort(port: types.input.core.v1.ContainerPort): types.input.core.v1.ServicePort;
|
125
|
-
declare function mapServiceToLabelSelector(service: core.v1.Service): types.input.meta.v1.LabelSelector;
|
126
|
-
|
127
|
-
interface FullBackendRef {
|
128
|
-
/**
|
129
|
-
* The name of the resource being referenced.
|
130
|
-
*/
|
131
|
-
name: Input<string>;
|
132
|
-
/**
|
133
|
-
* The namespace of the resource being referenced.
|
134
|
-
* May be undefined if the resource is not in a namespace.
|
135
|
-
*/
|
136
|
-
namespace?: Input<string | undefined>;
|
137
|
-
/**
|
138
|
-
* The port of the resource being referenced.
|
139
|
-
*/
|
140
|
-
port: Input<number>;
|
141
|
-
}
|
142
|
-
interface ServiceBackendRef {
|
143
|
-
/**
|
144
|
-
* The name of the service being referenced.
|
145
|
-
*/
|
146
|
-
service: Input<core.v1.Service>;
|
147
|
-
/**
|
148
|
-
* The port of the service being referenced.
|
149
|
-
*/
|
150
|
-
port: Input<number>;
|
151
|
-
}
|
152
|
-
type BackendRef = FullBackendRef | ServiceBackendRef | Service;
|
153
|
-
|
154
|
-
type HttpRouteArgs = Omit<CommonArgs, "namespace"> & {
|
155
|
-
/**
|
156
|
-
* The gateway to associate with the route.
|
157
|
-
*/
|
158
|
-
gateway: Input<gateway.v1.Gateway>;
|
159
|
-
/**
|
160
|
-
* The alias for `hostnames: [hostname]`.
|
161
|
-
*/
|
162
|
-
hostname?: Input<string>;
|
163
|
-
/**
|
164
|
-
* The rule of the route.
|
165
|
-
*/
|
166
|
-
rule?: Input<HttpRouteRuleArgs>;
|
167
|
-
/**
|
168
|
-
* The rules of the route.
|
169
|
-
*/
|
170
|
-
rules?: InputArray<HttpRouteRuleArgs>;
|
171
|
-
} & Omit<Partial<types$1.input.gateway.v1.HTTPRouteSpec>, "rules">;
|
172
|
-
type HttpRouteRuleArgs = Omit<types$1.input.gateway.v1.HTTPRouteSpecRules, "matches" | "filters" | "backendRefs"> & {
|
173
|
-
/**
|
174
|
-
* The conditions of the rule.
|
175
|
-
* Can be specified as string to match on the path.
|
176
|
-
*/
|
177
|
-
matches?: InputArray<HttpRouteRuleMatchOptions>;
|
178
|
-
/**
|
179
|
-
* The condition of the rule.
|
180
|
-
* Can be specified as string to match on the path.
|
181
|
-
*/
|
182
|
-
match?: Input<HttpRouteRuleMatchOptions>;
|
183
|
-
/**
|
184
|
-
* The filters of the rule.
|
185
|
-
*/
|
186
|
-
filters?: InputArray<types$1.input.gateway.v1.HTTPRouteSpecRulesFilters>;
|
187
|
-
/**
|
188
|
-
* The filter of the rule.
|
189
|
-
*/
|
190
|
-
filter?: Input<types$1.input.gateway.v1.HTTPRouteSpecRulesFilters>;
|
191
|
-
/**
|
192
|
-
* The service to route to.
|
193
|
-
*/
|
194
|
-
backend?: Input<BackendRef>;
|
195
|
-
};
|
196
|
-
type HttpRouteRuleMatchOptions = types$1.input.gateway.v1.HTTPRouteSpecRulesMatches | string;
|
197
|
-
declare class HttpRoute extends ComponentResource {
|
198
|
-
/**
|
199
|
-
* The underlying Kubernetes resource.
|
200
|
-
*/
|
201
|
-
readonly route: Output<gateway.v1.HTTPRoute>;
|
202
|
-
constructor(name: string, args: HttpRouteArgs, opts?: ComponentResourceOptions);
|
203
|
-
}
|
204
|
-
|
205
|
-
type PersistentVolumeClaimArgs = CommonArgs & types.input.core.v1.PersistentVolumeClaimSpec & {
|
206
|
-
/**
|
207
|
-
* The size of the volume to request.
|
208
|
-
*
|
209
|
-
* By default, the size is set to "100Mi".
|
210
|
-
*/
|
211
|
-
size?: string;
|
212
|
-
/**
|
213
|
-
* The cluster to create the resource in.
|
214
|
-
*/
|
215
|
-
cluster: Input<k8s.Cluster>;
|
216
|
-
};
|
217
|
-
declare abstract class PersistentVolumeClaim extends ComponentResource {
|
218
|
-
/**
|
219
|
-
* The cluster info associated with the pvc.
|
220
|
-
*/
|
221
|
-
readonly clusterInfo: Output<k8s.ClusterInfo>;
|
222
|
-
/**
|
223
|
-
* The metadata of the underlying Kubernetes pvc.
|
224
|
-
*/
|
225
|
-
readonly metadata: Output<types.output.meta.v1.ObjectMeta>;
|
226
|
-
/**
|
227
|
-
* The spec of the underlying Kubernetes pvc.
|
228
|
-
*/
|
229
|
-
readonly spec: Output<types.output.core.v1.PersistentVolumeClaimSpec>;
|
230
|
-
/**
|
231
|
-
* The status of the underlying Kubernetes pvc.
|
232
|
-
*/
|
233
|
-
readonly status: Output<types.output.core.v1.PersistentVolumeClaimStatus>;
|
234
|
-
protected constructor(type: string, name: string, args: Inputs, opts: ComponentResourceOptions,
|
235
|
-
/**
|
236
|
-
* The cluster info associated with the pvc.
|
237
|
-
*/
|
238
|
-
clusterInfo: Output<k8s.ClusterInfo>,
|
239
|
-
/**
|
240
|
-
* The metadata of the underlying Kubernetes pvc.
|
241
|
-
*/
|
242
|
-
metadata: Output<types.output.meta.v1.ObjectMeta>,
|
243
|
-
/**
|
244
|
-
* The spec of the underlying Kubernetes pvc.
|
245
|
-
*/
|
246
|
-
spec: Output<types.output.core.v1.PersistentVolumeClaimSpec>,
|
247
|
-
/**
|
248
|
-
* The status of the underlying Kubernetes pvc.
|
249
|
-
*/
|
250
|
-
status: Output<types.output.core.v1.PersistentVolumeClaimStatus>);
|
251
|
-
/**
|
252
|
-
* The Highstate service entity.
|
253
|
-
*/
|
254
|
-
get entity(): Output<k8s.PersistentVolumeClaim>;
|
255
|
-
static create(name: string, args: PersistentVolumeClaimArgs, opts: ComponentResourceOptions): PersistentVolumeClaim;
|
256
|
-
static of(name: string, entity: Input<k8s.PersistentVolumeClaim>, opts: ComponentResourceOptions): PersistentVolumeClaim;
|
257
|
-
}
|
258
|
-
|
259
|
-
type Container = Omit<PartialKeys<types.input.core.v1.Container, "name">, "volumeMounts"> & {
|
260
|
-
/**
|
261
|
-
* The single port to add to the container.
|
262
|
-
*/
|
263
|
-
port?: Input<types.input.core.v1.ContainerPort>;
|
264
|
-
/**
|
265
|
-
* The volume mount to attach to the container.
|
266
|
-
*/
|
267
|
-
volumeMount?: Input<ContainerVolumeMount>;
|
268
|
-
/**
|
269
|
-
* The volume mounts to attach to the container.
|
270
|
-
*/
|
271
|
-
volumeMounts?: InputArray<ContainerVolumeMount>;
|
272
|
-
/**
|
273
|
-
* The volume to include in the parent workload.
|
274
|
-
* It is like the `volumes` property, but defined at the container level.
|
275
|
-
* It will be defined as a volume mount in the parent workload automatically.
|
276
|
-
*/
|
277
|
-
volume?: Input<WorkloadVolume>;
|
278
|
-
/**
|
279
|
-
* The volumes to include in the parent workload.
|
280
|
-
* It is like the `volumes` property, but defined at the container level.
|
281
|
-
* It will be defined as a volume mount in the parent workload automatically.
|
282
|
-
*/
|
283
|
-
volumes?: InputArray<WorkloadVolume>;
|
284
|
-
/**
|
285
|
-
* The map of environment variables to set in the container.
|
286
|
-
* It is like the `env` property, but more convenient to use.
|
287
|
-
*/
|
288
|
-
environment?: Input<ContainerEnvironment>;
|
289
|
-
/**
|
290
|
-
* The source of environment variables to set in the container.
|
291
|
-
* It is like the `envFrom` property, but more convenient to use.
|
292
|
-
*/
|
293
|
-
environmentSource?: Input<ContainerEnvironmentSource>;
|
294
|
-
/**
|
295
|
-
* The sources of environment variables to set in the container.
|
296
|
-
* It is like the `envFrom` property, but more convenient to use.
|
297
|
-
*/
|
298
|
-
environmentSources?: InputArray<ContainerEnvironmentSource>;
|
299
|
-
};
|
300
|
-
type ContainerEnvironment = Record<string, Input<string | undefined | null | ContainerEnvironmentVariable>>;
|
301
|
-
type ContainerEnvironmentVariable = types.input.core.v1.EnvVarSource | {
|
302
|
-
/**
|
303
|
-
* The secret to select from.
|
304
|
-
*/
|
305
|
-
secret: Input<core.v1.Secret>;
|
306
|
-
/**
|
307
|
-
* The key of the secret to select from.
|
308
|
-
*/
|
309
|
-
key: string;
|
310
|
-
} | {
|
311
|
-
/**
|
312
|
-
* The config map to select from.
|
313
|
-
*/
|
314
|
-
configMap: Input<core.v1.ConfigMap>;
|
315
|
-
/**
|
316
|
-
* The key of the config map to select from.
|
317
|
-
*/
|
318
|
-
key: string;
|
319
|
-
};
|
320
|
-
type ContainerEnvironmentSource = types.input.core.v1.EnvFromSource | core.v1.ConfigMap | core.v1.Secret;
|
321
|
-
type ContainerVolumeMount = types.input.core.v1.VolumeMount | (Omit<types.input.core.v1.VolumeMount, "name"> & {
|
322
|
-
/**
|
323
|
-
* The volume to mount.
|
324
|
-
*/
|
325
|
-
volume: Input<WorkloadVolume>;
|
326
|
-
});
|
327
|
-
type WorkloadVolume = types.input.core.v1.Volume | core.v1.PersistentVolumeClaim | PersistentVolumeClaim | core.v1.ConfigMap | core.v1.Secret;
|
328
|
-
|
329
|
-
type WorkloadArgs = CommonArgs & {
|
330
|
-
container?: Input$1<Container>;
|
331
|
-
containers?: InputArray<Container>;
|
332
|
-
/**
|
333
|
-
* The cluster to create the resource in.
|
334
|
-
*/
|
335
|
-
cluster: Input$1<k8s.Cluster>;
|
336
|
-
};
|
337
|
-
type PublicWorkloadArgs = WorkloadArgs & {
|
338
|
-
service?: Input$1<Omit<ServiceArgs, "cluster" | "namespace">>;
|
339
|
-
httpRoute?: Input$1<Omit<HttpRouteArgs, "cluster" | "namespace">>;
|
340
|
-
patch?: Input$1<k8s.Deployment | k8s.StatefulSet>;
|
341
|
-
} & Partial<types.input.apps.v1.StatefulSetSpec>;
|
342
|
-
|
343
|
-
type DeploymentArgs = Omit<PublicWorkloadArgs, "patch"> & {
|
344
|
-
patch?: Input<k8s.Deployment>;
|
345
|
-
} & Omit<Partial<types.input.apps.v1.DeploymentSpec>, "template"> & {
|
346
|
-
template?: {
|
347
|
-
metadata?: types.input.meta.v1.ObjectMeta;
|
348
|
-
spec?: Partial<types.input.core.v1.PodSpec>;
|
349
|
-
};
|
350
|
-
};
|
351
|
-
declare abstract class Deployment extends ComponentResource {
|
352
|
-
/**
|
353
|
-
* The cluster info associated with the deployment.
|
354
|
-
*/
|
355
|
-
readonly clusterInfo: Output<k8s.ClusterInfo>;
|
356
|
-
/**
|
357
|
-
* The metadata of the underlying Kubernetes deployment.
|
358
|
-
*/
|
359
|
-
readonly metadata: Output<types.output.meta.v1.ObjectMeta>;
|
360
|
-
/**
|
361
|
-
* The spec of the underlying Kubernetes deployment.
|
362
|
-
*/
|
363
|
-
readonly spec: Output<types.output.apps.v1.DeploymentSpec>;
|
364
|
-
/**
|
365
|
-
* The status of the underlying Kubernetes deployment.
|
366
|
-
*/
|
367
|
-
readonly status: Output<types.output.apps.v1.DeploymentStatus>;
|
368
|
-
private readonly _service;
|
369
|
-
private readonly _httpRoute;
|
370
|
-
/**
|
371
|
-
* The resources associated with the deployment.
|
372
|
-
*/
|
373
|
-
readonly resources: InputArray<Resource>;
|
374
|
-
protected constructor(type: string, name: string, args: Inputs, opts: ComponentResourceOptions,
|
375
|
-
/**
|
376
|
-
* The cluster info associated with the deployment.
|
377
|
-
*/
|
378
|
-
clusterInfo: Output<k8s.ClusterInfo>,
|
379
|
-
/**
|
380
|
-
* The metadata of the underlying Kubernetes deployment.
|
381
|
-
*/
|
382
|
-
metadata: Output<types.output.meta.v1.ObjectMeta>,
|
383
|
-
/**
|
384
|
-
* The spec of the underlying Kubernetes deployment.
|
385
|
-
*/
|
386
|
-
spec: Output<types.output.apps.v1.DeploymentSpec>,
|
387
|
-
/**
|
388
|
-
* The status of the underlying Kubernetes deployment.
|
389
|
-
*/
|
390
|
-
status: Output<types.output.apps.v1.DeploymentStatus>, _service: Output<Service | undefined>, _httpRoute: Output<HttpRoute | undefined>,
|
391
|
-
/**
|
392
|
-
* The resources associated with the deployment.
|
393
|
-
*/
|
394
|
-
resources: InputArray<Resource>);
|
395
|
-
/**
|
396
|
-
* The Highstate deployment entity.
|
397
|
-
*/
|
398
|
-
get entity(): Output<k8s.Deployment>;
|
399
|
-
/**
|
400
|
-
* The service associated with the deployment.
|
401
|
-
*/
|
402
|
-
get service(): Output<Service>;
|
403
|
-
/**
|
404
|
-
* The HTTP route associated with the deployment.
|
405
|
-
*/
|
406
|
-
get httpRoute(): Output<HttpRoute>;
|
407
|
-
static create(name: string, args: DeploymentArgs, opts: ComponentResourceOptions): Deployment;
|
408
|
-
}
|
409
|
-
|
410
|
-
type StatefulSetArgs = Omit<PublicWorkloadArgs, "patch"> & {
|
411
|
-
patch?: Input<k8s.StatefulSet>;
|
412
|
-
} & Partial<types.input.apps.v1.StatefulSetSpec>;
|
413
|
-
declare abstract class StatefulSet extends ComponentResource {
|
414
|
-
/**
|
415
|
-
* The cluster info associated with the stateful set.
|
416
|
-
*/
|
417
|
-
readonly clusterInfo: Output<k8s.ClusterInfo>;
|
418
|
-
/**
|
419
|
-
* The metadata of the underlying Kubernetes stateful set.
|
420
|
-
*/
|
421
|
-
readonly metadata: Output<types.output.meta.v1.ObjectMeta>;
|
422
|
-
/**
|
423
|
-
* The spec of the underlying Kubernetes stateful set.
|
424
|
-
*/
|
425
|
-
readonly spec: Output<types.output.apps.v1.StatefulSetSpec>;
|
426
|
-
/**
|
427
|
-
* The status of the underlying Kubernetes stateful set.
|
428
|
-
*/
|
429
|
-
readonly status: Output<types.output.apps.v1.StatefulSetStatus>;
|
430
|
-
private readonly _service;
|
431
|
-
private readonly _httpRoute;
|
432
|
-
protected constructor(type: string, name: string, args: Inputs, opts: ComponentResourceOptions,
|
433
|
-
/**
|
434
|
-
* The cluster info associated with the stateful set.
|
435
|
-
*/
|
436
|
-
clusterInfo: Output<k8s.ClusterInfo>,
|
437
|
-
/**
|
438
|
-
* The metadata of the underlying Kubernetes stateful set.
|
439
|
-
*/
|
440
|
-
metadata: Output<types.output.meta.v1.ObjectMeta>,
|
441
|
-
/**
|
442
|
-
* The spec of the underlying Kubernetes stateful set.
|
443
|
-
*/
|
444
|
-
spec: Output<types.output.apps.v1.StatefulSetSpec>,
|
445
|
-
/**
|
446
|
-
* The status of the underlying Kubernetes stateful set.
|
447
|
-
*/
|
448
|
-
status: Output<types.output.apps.v1.StatefulSetStatus>, _service: Output<Service | undefined>, _httpRoute: Output<HttpRoute | undefined>);
|
449
|
-
/**
|
450
|
-
* The Highstate stateful set entity.
|
451
|
-
*/
|
452
|
-
get entity(): Output<k8s.StatefulSet>;
|
453
|
-
/**
|
454
|
-
* The service associated with the stateful set.
|
455
|
-
*/
|
456
|
-
get service(): Output<Service>;
|
457
|
-
/**
|
458
|
-
* The HTTP route associated with the stateful set.
|
459
|
-
*/
|
460
|
-
get httpRoute(): Output<HttpRoute>;
|
461
|
-
static create(name: string, args: StatefulSetArgs, opts: ComponentResourceOptions): StatefulSet;
|
462
|
-
}
|
463
|
-
|
464
|
-
type NetworkPolicyPort = {
|
465
|
-
/**
|
466
|
-
* The protocol to match.
|
467
|
-
*
|
468
|
-
* If not provided, "TCP" will be used.
|
469
|
-
*/
|
470
|
-
protocol?: string;
|
471
|
-
} & ({
|
472
|
-
/**
|
473
|
-
* The single port to match.
|
474
|
-
*/
|
475
|
-
port: number;
|
476
|
-
} | {
|
477
|
-
/**
|
478
|
-
* The range of ports to match.
|
479
|
-
*/
|
480
|
-
range: [start: number, end: number];
|
481
|
-
});
|
482
|
-
type IngressRuleArgs = {
|
483
|
-
/**
|
484
|
-
* Whether to allow all incoming traffic.
|
485
|
-
*
|
486
|
-
* If set to `true`, all other rules will be ignored for matched traffic.
|
487
|
-
*/
|
488
|
-
fromAll?: Input<boolean>;
|
489
|
-
/**
|
490
|
-
* The allowed cidr for incoming traffic.
|
491
|
-
*
|
492
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
493
|
-
*/
|
494
|
-
fromCidr?: Input<string>;
|
495
|
-
/**
|
496
|
-
* The list of allowed cidrs for incoming traffic.
|
497
|
-
*
|
498
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
499
|
-
*/
|
500
|
-
fromCidrs?: InputArray<string>;
|
501
|
-
/**
|
502
|
-
* The service to allow traffic from.
|
503
|
-
*
|
504
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
505
|
-
*/
|
506
|
-
fromService?: Input<core.v1.Service>;
|
507
|
-
/**
|
508
|
-
* The list of allowed services for incoming traffic.
|
509
|
-
*
|
510
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
511
|
-
*/
|
512
|
-
fromServices?: InputArray<core.v1.Service>;
|
513
|
-
/**
|
514
|
-
* The namespace to allow traffic from.
|
515
|
-
*
|
516
|
-
* If provided with `fromSelector(s)`, it will be ANDed with them.
|
517
|
-
* Otherwise, it will match all pods in the namespace.
|
518
|
-
*
|
519
|
-
* Will be ORed with other conditions inside the same rule (except ports and selectors).
|
520
|
-
*/
|
521
|
-
fromNamespace?: Input<NamespaceLike>;
|
522
|
-
/**
|
523
|
-
* The list of allowed namespaces for incoming traffic.
|
524
|
-
*
|
525
|
-
* If provided with `fromSelector(s)`, it will be ANDed with them.
|
526
|
-
* Otherwise, it will match all pods in the namespaces.
|
527
|
-
*
|
528
|
-
* Will be ORed with other conditions inside the same rule (except ports and selectors).
|
529
|
-
*/
|
530
|
-
fromNamespaces?: InputArray<NamespaceLike>;
|
531
|
-
/**
|
532
|
-
* The selector for incoming traffic.
|
533
|
-
*
|
534
|
-
* If provided with `fromNamespace(s)`, it will be ANDed with them.
|
535
|
-
* Otherwise, it will match pods in all namespaces.
|
536
|
-
*
|
537
|
-
* Will be ORed with other conditions inside the same rule (except ports and namespaces).
|
538
|
-
*/
|
539
|
-
fromSelector?: Input<SelectorLike>;
|
540
|
-
/**
|
541
|
-
* The list of selectors for incoming traffic.
|
542
|
-
*
|
543
|
-
* If provided with `fromNamespace(s)`, it will be ANDed with them.
|
544
|
-
* Otherwise, it will match pods in all namespaces.
|
545
|
-
*
|
546
|
-
* Will be ORed with other conditions inside the same rule (except ports and namespaces).
|
547
|
-
*/
|
548
|
-
fromSelectors?: InputArray<SelectorLike>;
|
549
|
-
/**
|
550
|
-
* The port to allow incoming traffic on.
|
551
|
-
*
|
552
|
-
* Will be ANDed with all conditions inside the same rule.
|
553
|
-
*/
|
554
|
-
toPort?: Input<NetworkPolicyPort>;
|
555
|
-
/**
|
556
|
-
* The list of allowed ports for incoming traffic.
|
557
|
-
*
|
558
|
-
* Will be ANDed with all conditions inside the same rule.
|
559
|
-
*/
|
560
|
-
toPorts?: InputArray<NetworkPolicyPort>;
|
561
|
-
};
|
562
|
-
type EgressRuleArgs = {
|
563
|
-
/**
|
564
|
-
* Whether to allow all outgoing traffic.
|
565
|
-
*
|
566
|
-
* If set to `true`, all other rules will be ignored for matched traffic.
|
567
|
-
*/
|
568
|
-
toAll?: Input<boolean>;
|
569
|
-
/**
|
570
|
-
* The allowed cidr for outgoing traffic.
|
571
|
-
*
|
572
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
573
|
-
*/
|
574
|
-
toCidr?: Input<string>;
|
575
|
-
/**
|
576
|
-
* The list of allowed cidrs for outgoing traffic.
|
577
|
-
*
|
578
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
579
|
-
*/
|
580
|
-
toCidrs?: InputArray<string>;
|
581
|
-
/**
|
582
|
-
* The FQDN to allow outgoing traffic.
|
583
|
-
*
|
584
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
585
|
-
*/
|
586
|
-
toFqdn?: Input<string>;
|
587
|
-
/**
|
588
|
-
* The list of allowed FQDNs for outgoing traffic.
|
589
|
-
*
|
590
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
591
|
-
*/
|
592
|
-
toFqdns?: InputArray<string>;
|
593
|
-
/**
|
594
|
-
* Either the FQDN or the IP address of the endpoint to allow outgoing traffic.
|
595
|
-
*
|
596
|
-
* Just a syntactic sugar for `toFqdn` and `toCidr` for cases when the endpoint can be both.
|
597
|
-
*
|
598
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
599
|
-
*/
|
600
|
-
toEndpoint?: Input<string>;
|
601
|
-
/**
|
602
|
-
* The list of allowed endpoints for outgoing traffic.
|
603
|
-
*
|
604
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
605
|
-
*/
|
606
|
-
toEndpoints?: InputArray<string>;
|
607
|
-
/**
|
608
|
-
* The service to allow traffic to.
|
609
|
-
*
|
610
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
611
|
-
*/
|
612
|
-
toService?: Input<core.v1.Service>;
|
613
|
-
/**
|
614
|
-
* The list of allowed services for outgoing traffic.
|
615
|
-
*
|
616
|
-
* Will be ORed with other conditions inside the same rule (except ports).
|
617
|
-
*/
|
618
|
-
toServices?: InputArray<core.v1.Service>;
|
619
|
-
/**
|
620
|
-
* The namespace to allow traffic to.
|
621
|
-
*
|
622
|
-
* If provided with `toSelector(s)`, it will be ANDed with them.
|
623
|
-
* Otherwise, it will match all pods in the namespace.
|
624
|
-
*
|
625
|
-
* Will be ORed with other conditions inside the same rule (except ports and selectors).
|
626
|
-
*/
|
627
|
-
toNamespace?: Input<NamespaceLike>;
|
628
|
-
/**
|
629
|
-
* The list of allowed namespaces for outgoing traffic.
|
630
|
-
*
|
631
|
-
* If provided with `toSelector(s)`, it will be ANDed with them.
|
632
|
-
* Otherwise, it will match all pods in the namespaces.
|
633
|
-
*
|
634
|
-
* Will be ORed with other conditions inside the same rule (except ports and selectors).
|
635
|
-
*/
|
636
|
-
toNamespaces?: InputArray<NamespaceLike>;
|
637
|
-
/**
|
638
|
-
* The selector for outgoing traffic.
|
639
|
-
*
|
640
|
-
* If provided with `toNamespace(s)`, it will be ANDe with them.
|
641
|
-
*
|
642
|
-
* Otherwise, it will match pods only in all namespaces.
|
643
|
-
*/
|
644
|
-
toSelector?: Input<SelectorLike>;
|
645
|
-
/**
|
646
|
-
* The list of selectors for outgoing traffic.
|
647
|
-
*
|
648
|
-
* If provided with `toNamespace(s)`, it will be ANDed with them.
|
649
|
-
* Otherwise, it will match pods only in all namespaces.
|
650
|
-
*/
|
651
|
-
toSelectors?: InputArray<SelectorLike>;
|
652
|
-
/**
|
653
|
-
* The port to allow outgoing traffic on.
|
654
|
-
*
|
655
|
-
* Will be ANDed with all conditions inside the same rule.
|
656
|
-
*/
|
657
|
-
toPort?: Input<NetworkPolicyPort>;
|
658
|
-
/**
|
659
|
-
* The list of allowed ports for outgoing traffic.
|
660
|
-
*
|
661
|
-
* Will be ANDed with all conditions inside the same rule.
|
662
|
-
*/
|
663
|
-
toPorts?: InputArray<NetworkPolicyPort>;
|
664
|
-
};
|
665
|
-
type NetworkPolicyArgs = CommonArgs & {
|
666
|
-
/**
|
667
|
-
* The description of this network policy.
|
668
|
-
*/
|
669
|
-
description?: Input<string>;
|
670
|
-
/**
|
671
|
-
* The pod selector for this network policy.
|
672
|
-
* If not provided, it will select all pods in the namespace.
|
673
|
-
*/
|
674
|
-
selector?: SelectorLike;
|
675
|
-
/**
|
676
|
-
* The rule for incoming traffic.
|
677
|
-
*/
|
678
|
-
ingressRule?: Input<IngressRuleArgs>;
|
679
|
-
/**
|
680
|
-
* The rules for incoming traffic.
|
681
|
-
*/
|
682
|
-
ingressRules?: InputArray<IngressRuleArgs>;
|
683
|
-
/**
|
684
|
-
* The rule for outgoing traffic.
|
685
|
-
*/
|
686
|
-
egressRule?: Input<EgressRuleArgs>;
|
687
|
-
/**
|
688
|
-
* The rules for outgoing traffic.
|
689
|
-
*/
|
690
|
-
egressRules?: InputArray<EgressRuleArgs>;
|
691
|
-
/**
|
692
|
-
* Enable the isolation of ingress traffic, so that only matched traffic can ingress.
|
693
|
-
*/
|
694
|
-
isolateIngress?: Input<boolean>;
|
695
|
-
/**
|
696
|
-
* Enable the isolation of egress traffic, so that only matched traffic can egress.
|
697
|
-
*/
|
698
|
-
isolateEgress?: Input<boolean>;
|
699
|
-
/**
|
700
|
-
* Allow the eggress traffic to the API server of the cluster.
|
701
|
-
*
|
702
|
-
* By default, `false`.
|
703
|
-
*/
|
704
|
-
allowKubeApiServer?: Input<boolean>;
|
705
|
-
/**
|
706
|
-
* Allow the eggress traffic to the DNS server of the cluster.
|
707
|
-
*
|
708
|
-
* By default, `false`.
|
709
|
-
*/
|
710
|
-
allowKubeDns?: Input<boolean>;
|
711
|
-
};
|
712
|
-
type FullNetworkPolicyArgs = NetworkPolicyArgs & {
|
713
|
-
/**
|
714
|
-
* The name of the CNI plugin to use for creating network policies.
|
715
|
-
* If not provided or set to `unknown`, it will use the native `NetworkPolicy` resource.
|
716
|
-
*/
|
717
|
-
cni?: Input<string | undefined>;
|
718
|
-
};
|
719
|
-
type NormalizedRuleArgs = {
|
720
|
-
all: boolean;
|
721
|
-
cidrs: string[];
|
722
|
-
fqdns: string[];
|
723
|
-
services: core.v1.Service[];
|
724
|
-
namespaces: NamespaceLike[];
|
725
|
-
selectors: SelectorLike[];
|
726
|
-
ports: NetworkPolicyPort[];
|
727
|
-
};
|
728
|
-
type NormalizedNetworkPolicyArgs = Omit<Unwrap<NetworkPolicyArgs>, "podSelector" | "ingressRule" | "ingressRules" | "egressRule" | "egressRules" | "isolateIngress" | "isolateEgress" | "allowKubeApiServer" | "allowKubeDNS"> & {
|
729
|
-
podSelector: Unwrap<types.input.meta.v1.LabelSelector>;
|
730
|
-
isolateIngress: boolean;
|
731
|
-
isolateEgress: boolean;
|
732
|
-
allowKubeApiServer: boolean;
|
733
|
-
ingressRules: NormalizedRuleArgs[];
|
734
|
-
egressRules: NormalizedRuleArgs[];
|
735
|
-
};
|
736
|
-
/**
|
737
|
-
* The abstract resource for creating network policies.
|
738
|
-
* Will use different resources depending on the environment.
|
739
|
-
*
|
740
|
-
* Note: In the worst case, it will create native `NetworkPolicy` resources and ignore some features like L7 rules.
|
741
|
-
*/
|
742
|
-
declare abstract class NetworkPolicy extends ComponentResource {
|
743
|
-
/**
|
744
|
-
* The underlying network policy resource.
|
745
|
-
*/
|
746
|
-
readonly networkPolicy: Output<Resource>;
|
747
|
-
protected constructor(name: string, args: Unwrap<NetworkPolicyArgs>, opts?: ResourceOptions);
|
748
|
-
private static mapCidrFromEndpoint;
|
749
|
-
protected abstract create(name: string, args: NormalizedNetworkPolicyArgs, opts?: ResourceOptions): Input<Resource>;
|
750
|
-
private static readonly supportedCNIs;
|
751
|
-
static create(name: string, args: FullNetworkPolicyArgs, opts: ResourceOptions): Output<NetworkPolicy>;
|
752
|
-
static allowInsideNamespace(namespace: Input<NamespaceLike>, k8sCluster: Input<k8s.Cluster>, opts: ResourceOptions): Output<NetworkPolicy>;
|
753
|
-
static allowKubeApiServer(namespace: Input<NamespaceLike>, k8sCluster: Input<k8s.Cluster>, opts: ResourceOptions): Output<NetworkPolicy>;
|
754
|
-
static allowKubeDns(namespace: Input<NamespaceLike>, k8sCluster: Input<k8s.Cluster>, opts: ResourceOptions): Output<NetworkPolicy>;
|
755
|
-
static allowAllEgress(namespace: Input<NamespaceLike>, k8sCluster: Input<k8s.Cluster>, opts: ResourceOptions): Output<NetworkPolicy>;
|
756
|
-
}
|
757
|
-
|
758
|
-
type UseAccessPointResult = {
|
759
|
-
/**
|
760
|
-
* The gateway instance created according to the access point.
|
761
|
-
*/
|
762
|
-
gateway: gateway.v1.Gateway;
|
763
|
-
/**
|
764
|
-
* The DNS record associated created according to the access point and gateway.
|
765
|
-
*/
|
766
|
-
dnsRecords: DnsRecord[];
|
767
|
-
/**
|
768
|
-
* The network policies associated with the access point.
|
769
|
-
*/
|
770
|
-
networkPolicies: NetworkPolicy[];
|
771
|
-
};
|
772
|
-
type UseAccessPointArgs = Omit<CreateGatewayArgs, "gateway"> & {
|
773
|
-
accessPoint: Input<k8s.AccessPoint>;
|
774
|
-
};
|
775
|
-
declare function useAccessPoint(args: UseAccessPointArgs): Promise<UseAccessPointResult>;
|
776
|
-
type StandardAccessPointArgs = {
|
777
|
-
fqdn: string;
|
778
|
-
};
|
779
|
-
type StandardAccessPointInputs = {
|
780
|
-
accessPoint: Output<k8s.AccessPoint>;
|
781
|
-
k8sCluster: Output<k8s.Cluster>;
|
782
|
-
};
|
783
|
-
declare function useStandardAcessPoint(appName: string, namespace: core.v1.Namespace, args: StandardAccessPointArgs, inputs: StandardAccessPointInputs, provider: Provider): Promise<UseAccessPointResult>;
|
784
|
-
type CreateGatewayArgs = {
|
785
|
-
name: string;
|
786
|
-
namespace: Input<core.v1.Namespace>;
|
787
|
-
annotations?: Input<Record<string, string>>;
|
788
|
-
fqdn?: Input<string>;
|
789
|
-
fqdns?: InputArray<string>;
|
790
|
-
gateway: Input<k8s.Gateway>;
|
791
|
-
clusterInfo: Input<k8s.ClusterInfo>;
|
792
|
-
provider: Provider;
|
793
|
-
};
|
794
|
-
|
795
|
-
type ScriptDistribution = "alpine" | "ubuntu";
|
796
|
-
type DistributionEnvironment = {
|
797
|
-
/**
|
798
|
-
* The utility packages that should be installed before running "preInstallScripts".
|
799
|
-
*
|
800
|
-
* Useful for installing tools like `curl` to install additional repositories.
|
801
|
-
*/
|
802
|
-
preInstallPackages?: InputArray<string>;
|
803
|
-
/**
|
804
|
-
* The pre-install scripts that should be run before installing packages.
|
805
|
-
* Typically, these scripts are used to install additional repositories.
|
806
|
-
*/
|
807
|
-
preInstallScripts?: InputMap<string>;
|
808
|
-
/**
|
809
|
-
* The packages that are available in the environment.
|
810
|
-
*/
|
811
|
-
packages?: InputArray<string>;
|
812
|
-
};
|
813
|
-
type ScriptEnvironment = {
|
814
|
-
[distribution in ScriptDistribution]?: DistributionEnvironment;
|
815
|
-
} & {
|
816
|
-
/**
|
817
|
-
* The setup scripts that should be run before the script.
|
818
|
-
*/
|
819
|
-
setupScripts?: InputMap<string>;
|
820
|
-
/**
|
821
|
-
* The cleanup scripts that should be run after the script.
|
822
|
-
*/
|
823
|
-
cleanupScripts?: InputMap<string>;
|
824
|
-
/**
|
825
|
-
* The arbitrary scripts available in the environment.
|
826
|
-
*/
|
827
|
-
scripts?: InputMap<string>;
|
828
|
-
/**
|
829
|
-
* The volumes that should be defined in the environment.
|
830
|
-
*/
|
831
|
-
volumes?: InputArray<WorkloadVolume>;
|
832
|
-
/**
|
833
|
-
* The volume mounts that should be defined in the environment.
|
834
|
-
*/
|
835
|
-
volumeMounts?: InputArray<ContainerVolumeMount>;
|
836
|
-
/**
|
837
|
-
* The environment variables that should be defined in the environment.
|
838
|
-
*/
|
839
|
-
environment?: Input<ContainerEnvironment>;
|
840
|
-
};
|
841
|
-
|
842
|
-
type ScriptBundleArgs = CommonArgs & {
|
843
|
-
/**
|
844
|
-
* The environment to bundle the scripts from.
|
845
|
-
*/
|
846
|
-
environment?: Input$1<ScriptEnvironment>;
|
847
|
-
/**
|
848
|
-
* The environments to bundle the scripts from.
|
849
|
-
*/
|
850
|
-
environments?: InputArray<ScriptEnvironment>;
|
851
|
-
/**
|
852
|
-
* The distribution to use for the scripts.
|
853
|
-
*/
|
854
|
-
distribution: ScriptDistribution;
|
855
|
-
};
|
856
|
-
declare class ScriptBundle extends ComponentResource$1 {
|
857
|
-
/**
|
858
|
-
* The config map containing the scripts.
|
859
|
-
*/
|
860
|
-
readonly configMap: Output$1<core.v1.ConfigMap>;
|
861
|
-
/**
|
862
|
-
* The volumes that should be included in the workload.
|
863
|
-
*/
|
864
|
-
readonly volumes: Output$1<WorkloadVolume[]>;
|
865
|
-
/**
|
866
|
-
* The volume mounts that should be defined in the container.
|
867
|
-
*/
|
868
|
-
readonly volumeMounts: Output$1<ContainerVolumeMount[]>;
|
869
|
-
/**
|
870
|
-
* The environment variables that should be defined in the container.
|
871
|
-
*/
|
872
|
-
readonly environment: Output$1<ContainerEnvironment>;
|
873
|
-
/**
|
874
|
-
* The distribution to use for the scripts.
|
875
|
-
*/
|
876
|
-
readonly distribution: ScriptDistribution;
|
877
|
-
constructor(name: string, args: ScriptBundleArgs, opts?: ComponentResourceOptions$1);
|
878
|
-
}
|
879
|
-
|
880
|
-
interface ScriptContainer extends Container {
|
881
|
-
/**
|
882
|
-
* The script bundle to use.
|
883
|
-
*/
|
884
|
-
bundle: Input$1<ScriptBundle>;
|
885
|
-
/**
|
886
|
-
* The name of the main script to run.
|
887
|
-
* The script must be available in the bundle.
|
888
|
-
*/
|
889
|
-
main: Input$1<string>;
|
890
|
-
}
|
891
|
-
/**
|
892
|
-
* Creates a spec for a container that runs a script.
|
893
|
-
* This spec can be used to create a complete workload or an init container.
|
894
|
-
*
|
895
|
-
* @param options The options to create the container spec.
|
896
|
-
* @returns The container spec.
|
897
|
-
*/
|
898
|
-
declare function createScriptContainer(options: ScriptContainer): Output$1<Container>;
|
899
|
-
|
900
|
-
type JobArgs = CommonArgs & {
|
901
|
-
container?: Input<Container>;
|
902
|
-
containers?: InputArray<Container>;
|
903
|
-
} & Omit<Partial<types.input.batch.v1.JobSpec>, "template"> & {
|
904
|
-
template?: {
|
905
|
-
metadata?: types.input.meta.v1.ObjectMeta;
|
906
|
-
spec?: Partial<types.input.core.v1.PodSpec>;
|
907
|
-
};
|
908
|
-
};
|
909
|
-
declare class Job extends ComponentResource {
|
910
|
-
/**
|
911
|
-
* The underlying Kubernetes job.
|
912
|
-
*/
|
913
|
-
readonly job: Output<batch.v1.Job>;
|
914
|
-
constructor(name: string, args: JobArgs, opts?: ComponentResourceOptions);
|
915
|
-
}
|
916
|
-
|
917
|
-
type CronJobArgs = CommonArgs & {
|
918
|
-
container?: Input<Container>;
|
919
|
-
containers?: InputArray<Container>;
|
920
|
-
} & Omit<RequiredKeys<Partial<types.input.batch.v1.CronJobSpec>, "schedule">, "jobTemplate"> & {
|
921
|
-
jobTemplate?: {
|
922
|
-
metadata?: types.input.meta.v1.ObjectMeta;
|
923
|
-
spec?: Omit<types.input.batch.v1.JobSpec, "template"> & {
|
924
|
-
template?: {
|
925
|
-
metadata?: types.input.meta.v1.ObjectMeta;
|
926
|
-
spec?: Partial<types.input.core.v1.PodSpec>;
|
927
|
-
};
|
928
|
-
};
|
929
|
-
};
|
930
|
-
};
|
931
|
-
declare class CronJob extends ComponentResource {
|
932
|
-
/**
|
933
|
-
* The underlying Kubernetes job.
|
934
|
-
*/
|
935
|
-
readonly cronJob: Output<batch.v1.CronJob>;
|
936
|
-
constructor(name: string, args: CronJobArgs, opts?: ComponentResourceOptions);
|
937
|
-
}
|
938
|
-
|
939
|
-
type ChartArgs = Omit<helm.v4.ChartArgs, "chart" | "version" | "repositoryOpts" | "namespace"> & {
|
940
|
-
/**
|
941
|
-
* The namespace to deploy the chart into.
|
942
|
-
*/
|
943
|
-
namespace?: Input$1<NamespaceLike>;
|
944
|
-
/**
|
945
|
-
* The custom name of the primary service exposed by the chart.
|
946
|
-
*
|
947
|
-
* By default, it is the same as the chart name.
|
948
|
-
*/
|
949
|
-
serviceName?: string;
|
950
|
-
/**
|
951
|
-
* The manifest of the chart to resolve.
|
952
|
-
*/
|
953
|
-
chart: ChartManifest;
|
954
|
-
/**
|
955
|
-
* The cluster to create the resource in.
|
956
|
-
*/
|
957
|
-
cluster: Input$1<k8s.Cluster>;
|
958
|
-
/**
|
959
|
-
* The http route args to bind the service to.
|
960
|
-
*/
|
961
|
-
httpRoute?: Input$1<HttpRouteArgs>;
|
962
|
-
};
|
963
|
-
declare class Chart extends ComponentResource$1 {
|
964
|
-
private readonly name;
|
965
|
-
private readonly args;
|
966
|
-
private readonly opts?;
|
967
|
-
/**
|
968
|
-
* The underlying Helm chart.
|
969
|
-
*/
|
970
|
-
readonly chart: Output$1<helm.v4.Chart>;
|
971
|
-
/**
|
972
|
-
* The HTTP route associated with the deployment.
|
973
|
-
*/
|
974
|
-
readonly httpRoute: Output$1<HttpRoute | undefined>;
|
975
|
-
constructor(name: string, args: ChartArgs, opts?: ComponentResourceOptions$1 | undefined);
|
976
|
-
get service(): Output$1<Service>;
|
977
|
-
private readonly services;
|
978
|
-
getServiceOutput(name: string | undefined): Output$1<Service>;
|
979
|
-
getService(name?: string): Promise<Service>;
|
980
|
-
}
|
981
|
-
type RenderedChartArgs = {
|
982
|
-
/**
|
983
|
-
* The namespace to deploy the chart into.
|
984
|
-
*/
|
985
|
-
namespace?: Input$1<NamespaceLike>;
|
986
|
-
/**
|
987
|
-
* The manifest of the chart to resolve.
|
988
|
-
*/
|
989
|
-
chart: ChartManifest;
|
990
|
-
/**
|
991
|
-
* The values to pass to the chart.
|
992
|
-
*/
|
993
|
-
values?: InputMap<string>;
|
994
|
-
};
|
995
|
-
declare class RenderedChart extends ComponentResource$1 {
|
996
|
-
/**
|
997
|
-
* The rendered manifest of the Helm chart.
|
998
|
-
*/
|
999
|
-
readonly manifest: Output$1<string>;
|
1000
|
-
/**
|
1001
|
-
* The underlying command used to render the chart.
|
1002
|
-
*/
|
1003
|
-
readonly command: Output$1<local.Command>;
|
1004
|
-
constructor(name: string, args: RenderedChartArgs, opts?: ComponentResourceOptions$1);
|
1005
|
-
}
|
1006
|
-
type ChartManifest = {
|
1007
|
-
repo: string;
|
1008
|
-
name: string;
|
1009
|
-
version: string;
|
1010
|
-
sha256: string;
|
1011
|
-
};
|
1012
|
-
/**
|
1013
|
-
* Downloads or reuses the Helm chart according to the charts.json file.
|
1014
|
-
* Returns the full path to the chart's .tgz file.
|
1015
|
-
*
|
1016
|
-
* @param manifest The manifest of the Helm chart.
|
1017
|
-
*/
|
1018
|
-
declare function resolveHelmChart(manifest: ChartManifest): Promise<string>;
|
1019
|
-
/**
|
1020
|
-
* Extracts the service with the given name from the chart resources.
|
1021
|
-
* Throws an error if the service is not found.
|
1022
|
-
*
|
1023
|
-
* @param chart The Helm chart.
|
1024
|
-
* @param name The name of the service.
|
1025
|
-
*/
|
1026
|
-
declare function getChartServiceOutput(chart: helm.v4.Chart, name: string): Output$1<core.v1.Service>;
|
1027
|
-
/**
|
1028
|
-
* Extracts the service with the given name from the chart resources.
|
1029
|
-
* Throws an error if the service is not found.
|
1030
|
-
*
|
1031
|
-
* @param chart The Helm chart.
|
1032
|
-
* @param name The name of the service.
|
1033
|
-
*/
|
1034
|
-
declare function getChartService(chart: helm.v4.Chart, name: string): Promise<core.v1.Service>;
|
1035
|
-
|
1036
|
-
export { Chart, type ChartArgs, type ChartManifest, type CommonArgs, type Container, type ContainerEnvironment, type ContainerEnvironmentSource, type ContainerEnvironmentVariable, type ContainerVolumeMount, CronJob, type CronJobArgs, Deployment, type DeploymentArgs, type FullNetworkPolicyArgs, HttpRoute, type HttpRouteArgs, Job, type JobArgs, type NamespaceLike, NetworkPolicy, type NetworkPolicyArgs, type NetworkPolicyPort, type NormalizedNetworkPolicyArgs, type NormalizedRuleArgs, PersistentVolumeClaim, type PersistentVolumeClaimArgs, RenderedChart, type RenderedChartArgs, ScriptBundle, type ScriptBundleArgs, type ScriptContainer, type ScriptDistribution, type ScriptEnvironment, type SelectorLike, Service, type ServiceArgs, StatefulSet, type StatefulSetArgs, type WorkloadVolume, createNamespace, getProvider as createProvider, createScriptContainer, getAppDisplayName, getAppName, getChartService, getChartServiceOutput, getNamespace, mapContainerPortToServicePort, mapMetadata, mapNamespaceLikeToNamespaceName, mapNamespaceNameToSelector, mapSelectorLikeToSelector, mapServiceToLabelSelector, resolveHelmChart, useAccessPoint, useStandardAcessPoint };
|