@sealant/api-contracts-next 0.40.0-next.933 → 0.40.0-next.935
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/core-api/control-plane.d.ts +3352 -3214
- package/dist/core-api/workspaces.d.ts +477 -22
- package/dist/core-api/workspaces.js +224 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/network-policy.d.ts +113 -0
- package/dist/network-policy.js +292 -0
- package/package.json +6 -2
|
@@ -12,9 +12,63 @@ import { BudgetExceededError } from "./budgets.js";
|
|
|
12
12
|
export declare const workspaceStatusSchema: Schema.Literals<readonly ["queued", "running", "ready", "failed", "cancelled", "stopped", "retained"]>;
|
|
13
13
|
export type WorkspaceStatus = typeof workspaceStatusSchema.Type;
|
|
14
14
|
/** Request families. A deployment registers only the adapters it can actually launch. */
|
|
15
|
-
export declare const runtimeAdapterIds: readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"];
|
|
15
|
+
export declare const runtimeAdapterIds: readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"];
|
|
16
|
+
/**
|
|
17
|
+
* A workspace's network policy (`spec.networkPolicy`, workspace isolation architecture §8.4).
|
|
18
|
+
* `standard`: public internet less private, metadata and host addresses. `restricted`: only the
|
|
19
|
+
* hosts, mirrors and resources it lists. A Docker workspace with a `restricted` policy, or with
|
|
20
|
+
* any brokered secret, runs behind its own egress proxy. The rules are `networkPolicyProblems`'.
|
|
21
|
+
*/
|
|
22
|
+
export declare const networkPolicySchema: Schema.Struct<{
|
|
23
|
+
readonly mode: Schema.Literals<readonly ["standard", "restricted"]>;
|
|
24
|
+
readonly policyHash: Schema.String;
|
|
25
|
+
readonly sourcePolicyId: Schema.optional<Schema.String>;
|
|
26
|
+
readonly sourcePolicyRevision: Schema.optional<Schema.Int>;
|
|
27
|
+
readonly requireVmIsolation: Schema.optional<Schema.Boolean>;
|
|
28
|
+
readonly allowHosts: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
29
|
+
readonly host: Schema.String;
|
|
30
|
+
readonly ports: Schema.optional<Schema.$Array<Schema.Int>>;
|
|
31
|
+
readonly inspectTls: Schema.optional<Schema.Boolean>;
|
|
32
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
33
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
34
|
+
}>>>;
|
|
35
|
+
readonly allowMirrors: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
36
|
+
readonly name: Schema.Literals<readonly ["npm", "docker"]>;
|
|
37
|
+
readonly host: Schema.String;
|
|
38
|
+
readonly port: Schema.Int;
|
|
39
|
+
}>>>;
|
|
40
|
+
readonly allowResources: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
41
|
+
readonly name: Schema.String;
|
|
42
|
+
readonly host: Schema.String;
|
|
43
|
+
readonly port: Schema.Int;
|
|
44
|
+
readonly guestIp: Schema.String;
|
|
45
|
+
}>>>;
|
|
46
|
+
}>;
|
|
47
|
+
export type NetworkPolicySpec = typeof networkPolicySchema.Type;
|
|
48
|
+
/**
|
|
49
|
+
* Project secrets the workspace never holds (`spec.brokeredSecrets`): it reads `placeholder` from
|
|
50
|
+
* `name`, and its egress proxy swaps in the real value, only inside `headerName` and only on
|
|
51
|
+
* HTTPS to one of `bindHosts`. The rules are `brokeredSecretsProblems`'.
|
|
52
|
+
*/
|
|
53
|
+
export declare const brokeredSecretsSchema: Schema.$Array<Schema.Struct<{
|
|
54
|
+
readonly secretId: Schema.String;
|
|
55
|
+
readonly name: Schema.String;
|
|
56
|
+
readonly placeholder: Schema.String;
|
|
57
|
+
readonly secretRef: Schema.String;
|
|
58
|
+
readonly headerName: Schema.String;
|
|
59
|
+
readonly bindHosts: Schema.$Array<Schema.String>;
|
|
60
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
61
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
62
|
+
}>>;
|
|
63
|
+
export type BrokeredSecretsSpec = typeof brokeredSecretsSchema.Type;
|
|
64
|
+
/**
|
|
65
|
+
* The values of a request's brokered secrets, keyed by each secret's `secretRef`. Sealed with the
|
|
66
|
+
* credential key at rest, handed only to the workspace's egress proxy, and never part of the spec,
|
|
67
|
+
* the workspace's environment or any read response.
|
|
68
|
+
*/
|
|
69
|
+
export declare const brokeredSecretValuesSchema: Schema.$Record<Schema.String, Schema.String>;
|
|
16
70
|
export declare const workspaceRuntimeSchema: Schema.Struct<{
|
|
17
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
71
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
18
72
|
/**
|
|
19
73
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
20
74
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -41,7 +95,7 @@ export declare const workspaceSshTargetSchema: Schema.Struct<{
|
|
|
41
95
|
readonly workspaceId: Schema.String;
|
|
42
96
|
readonly attemptId: Schema.String;
|
|
43
97
|
readonly runtime: Schema.Struct<{
|
|
44
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
98
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
45
99
|
readonly resourceId: Schema.String;
|
|
46
100
|
readonly reference: Schema.String;
|
|
47
101
|
readonly status: Schema.Literals<readonly ["pending", "running", "ready", "failed", "stopped"]>;
|
|
@@ -267,6 +321,13 @@ export declare const createWorkspaceRequestSchema: Schema.Struct<{
|
|
|
267
321
|
readonly spec: Schema.Unknown;
|
|
268
322
|
readonly secretEnv: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
|
|
269
323
|
readonly captureToken: Schema.optional<Schema.String>;
|
|
324
|
+
/**
|
|
325
|
+
* The values of the spec's `brokeredSecrets`, keyed by `secretRef`: required for each one, and
|
|
326
|
+
* refused without them. Sealed like `secretEnv`, but never delivered to the workspace: only its
|
|
327
|
+
* egress proxy receives them. Kept sealed for the workspace's life, so a restart and a restarted
|
|
328
|
+
* proxy get them again.
|
|
329
|
+
*/
|
|
330
|
+
readonly brokeredSecretValues: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
|
|
270
331
|
readonly ttlSeconds: Schema.optional<Schema.Int>;
|
|
271
332
|
/**
|
|
272
333
|
* Makes the create idempotent for this owner: a repeated create with the same key returns the
|
|
@@ -963,7 +1024,7 @@ export type RuntimeOsFamily = (typeof runtimeOsFamilies)[number];
|
|
|
963
1024
|
* runtime for an item it marks unsupported is refused with that item's `message`.
|
|
964
1025
|
*/
|
|
965
1026
|
export declare const runtimeSupportSchema: Schema.Struct<{
|
|
966
|
-
readonly runtime: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
1027
|
+
readonly runtime: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
967
1028
|
/** The managed OS families that run on this runtime (`target.os.family`). */
|
|
968
1029
|
readonly os: Schema.Struct<{
|
|
969
1030
|
readonly ubuntu: Schema.Union<readonly [Schema.Struct<{
|
|
@@ -1066,6 +1127,41 @@ export declare const runtimeSupportSchema: Schema.Struct<{
|
|
|
1066
1127
|
readonly charged: Schema.Boolean;
|
|
1067
1128
|
readonly message: Schema.String;
|
|
1068
1129
|
}>;
|
|
1130
|
+
/**
|
|
1131
|
+
* What the runtime enforces of a network policy (`spec.networkPolicy`, `spec.brokeredSecrets`). A
|
|
1132
|
+
* create that asks for an unsupported item is refused, never run with less. Absent from control
|
|
1133
|
+
* planes that predate network policies.
|
|
1134
|
+
*/
|
|
1135
|
+
readonly networkPolicy: Schema.optional<Schema.Struct<{
|
|
1136
|
+
/** The workspace in its own VM (`networkPolicy.requireVmIsolation`). */
|
|
1137
|
+
readonly vmIsolation: Schema.Union<readonly [Schema.Struct<{
|
|
1138
|
+
readonly supported: Schema.Literal<true>;
|
|
1139
|
+
}>, Schema.Struct<{
|
|
1140
|
+
readonly supported: Schema.Literal<false>;
|
|
1141
|
+
readonly message: Schema.String;
|
|
1142
|
+
}>]>;
|
|
1143
|
+
/** `networkPolicy.mode: "restricted"`. */
|
|
1144
|
+
readonly restricted: Schema.Union<readonly [Schema.Struct<{
|
|
1145
|
+
readonly supported: Schema.Literal<true>;
|
|
1146
|
+
}>, Schema.Struct<{
|
|
1147
|
+
readonly supported: Schema.Literal<false>;
|
|
1148
|
+
readonly message: Schema.String;
|
|
1149
|
+
}>]>;
|
|
1150
|
+
/** `restricted` together with Docker inside the workspace. */
|
|
1151
|
+
readonly restrictedWithDocker: Schema.Union<readonly [Schema.Struct<{
|
|
1152
|
+
readonly supported: Schema.Literal<true>;
|
|
1153
|
+
}>, Schema.Struct<{
|
|
1154
|
+
readonly supported: Schema.Literal<false>;
|
|
1155
|
+
readonly message: Schema.String;
|
|
1156
|
+
}>]>;
|
|
1157
|
+
/** Any `brokeredSecrets`, whatever the mode. */
|
|
1158
|
+
readonly brokeredSecrets: Schema.Union<readonly [Schema.Struct<{
|
|
1159
|
+
readonly supported: Schema.Literal<true>;
|
|
1160
|
+
}>, Schema.Struct<{
|
|
1161
|
+
readonly supported: Schema.Literal<false>;
|
|
1162
|
+
readonly message: Schema.String;
|
|
1163
|
+
}>]>;
|
|
1164
|
+
}>>;
|
|
1069
1165
|
}>;
|
|
1070
1166
|
export type RuntimeSupport = typeof runtimeSupportSchema.Type;
|
|
1071
1167
|
/**
|
|
@@ -1074,9 +1170,9 @@ export type RuntimeSupport = typeof runtimeSupportSchema.Type;
|
|
|
1074
1170
|
* A runtime that is not listed is one this install cannot launch.
|
|
1075
1171
|
*/
|
|
1076
1172
|
export declare const workspaceRuntimesResponseSchema: Schema.Struct<{
|
|
1077
|
-
readonly default: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
1173
|
+
readonly default: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
1078
1174
|
readonly runtimes: Schema.$Array<Schema.Struct<{
|
|
1079
|
-
readonly runtime: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
1175
|
+
readonly runtime: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
1080
1176
|
/** The managed OS families that run on this runtime (`target.os.family`). */
|
|
1081
1177
|
readonly os: Schema.Struct<{
|
|
1082
1178
|
readonly ubuntu: Schema.Union<readonly [Schema.Struct<{
|
|
@@ -1179,6 +1275,41 @@ export declare const workspaceRuntimesResponseSchema: Schema.Struct<{
|
|
|
1179
1275
|
readonly charged: Schema.Boolean;
|
|
1180
1276
|
readonly message: Schema.String;
|
|
1181
1277
|
}>;
|
|
1278
|
+
/**
|
|
1279
|
+
* What the runtime enforces of a network policy (`spec.networkPolicy`, `spec.brokeredSecrets`). A
|
|
1280
|
+
* create that asks for an unsupported item is refused, never run with less. Absent from control
|
|
1281
|
+
* planes that predate network policies.
|
|
1282
|
+
*/
|
|
1283
|
+
readonly networkPolicy: Schema.optional<Schema.Struct<{
|
|
1284
|
+
/** The workspace in its own VM (`networkPolicy.requireVmIsolation`). */
|
|
1285
|
+
readonly vmIsolation: Schema.Union<readonly [Schema.Struct<{
|
|
1286
|
+
readonly supported: Schema.Literal<true>;
|
|
1287
|
+
}>, Schema.Struct<{
|
|
1288
|
+
readonly supported: Schema.Literal<false>;
|
|
1289
|
+
readonly message: Schema.String;
|
|
1290
|
+
}>]>;
|
|
1291
|
+
/** `networkPolicy.mode: "restricted"`. */
|
|
1292
|
+
readonly restricted: Schema.Union<readonly [Schema.Struct<{
|
|
1293
|
+
readonly supported: Schema.Literal<true>;
|
|
1294
|
+
}>, Schema.Struct<{
|
|
1295
|
+
readonly supported: Schema.Literal<false>;
|
|
1296
|
+
readonly message: Schema.String;
|
|
1297
|
+
}>]>;
|
|
1298
|
+
/** `restricted` together with Docker inside the workspace. */
|
|
1299
|
+
readonly restrictedWithDocker: Schema.Union<readonly [Schema.Struct<{
|
|
1300
|
+
readonly supported: Schema.Literal<true>;
|
|
1301
|
+
}>, Schema.Struct<{
|
|
1302
|
+
readonly supported: Schema.Literal<false>;
|
|
1303
|
+
readonly message: Schema.String;
|
|
1304
|
+
}>]>;
|
|
1305
|
+
/** Any `brokeredSecrets`, whatever the mode. */
|
|
1306
|
+
readonly brokeredSecrets: Schema.Union<readonly [Schema.Struct<{
|
|
1307
|
+
readonly supported: Schema.Literal<true>;
|
|
1308
|
+
}>, Schema.Struct<{
|
|
1309
|
+
readonly supported: Schema.Literal<false>;
|
|
1310
|
+
readonly message: Schema.String;
|
|
1311
|
+
}>]>;
|
|
1312
|
+
}>>;
|
|
1182
1313
|
}>>;
|
|
1183
1314
|
}>;
|
|
1184
1315
|
export type WorkspaceRuntimesResponse = typeof workspaceRuntimesResponseSchema.Type;
|
|
@@ -1678,7 +1809,7 @@ export declare const createWorkspaceResponseSchema: Schema.Struct<{
|
|
|
1678
1809
|
* asynchronous); a replayed create carries the workspace's current one.
|
|
1679
1810
|
*/
|
|
1680
1811
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
1681
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
1812
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
1682
1813
|
/**
|
|
1683
1814
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
1684
1815
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -1772,7 +1903,7 @@ export declare const workspaceSummarySchema: Schema.Struct<{
|
|
|
1772
1903
|
readonly repository: Schema.optional<Schema.String>;
|
|
1773
1904
|
readonly tag: Schema.optional<Schema.String>;
|
|
1774
1905
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
1775
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
1906
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
1776
1907
|
/**
|
|
1777
1908
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
1778
1909
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -2003,7 +2134,7 @@ export declare const workspaceDetailsSchema: Schema.Struct<{
|
|
|
2003
2134
|
readonly repository: Schema.optional<Schema.String>;
|
|
2004
2135
|
readonly tag: Schema.optional<Schema.String>;
|
|
2005
2136
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
2006
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
2137
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
2007
2138
|
/**
|
|
2008
2139
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
2009
2140
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -2235,7 +2366,7 @@ export declare const listWorkspacesResponseSchema: Schema.Struct<{
|
|
|
2235
2366
|
readonly repository: Schema.optional<Schema.String>;
|
|
2236
2367
|
readonly tag: Schema.optional<Schema.String>;
|
|
2237
2368
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
2238
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
2369
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
2239
2370
|
/**
|
|
2240
2371
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
2241
2372
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -2390,7 +2521,7 @@ export declare const workspaceAttemptSummarySchema: Schema.Struct<{
|
|
|
2390
2521
|
readonly triggerType: Schema.Literals<readonly ["manual", "schedule", "api", "retry"]>;
|
|
2391
2522
|
readonly triggerRef: Schema.optional<Schema.String>;
|
|
2392
2523
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
2393
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
2524
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
2394
2525
|
/**
|
|
2395
2526
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
2396
2527
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -2524,7 +2655,7 @@ export declare const listWorkspaceAttemptsResponseSchema: Schema.Struct<{
|
|
|
2524
2655
|
readonly triggerType: Schema.Literals<readonly ["manual", "schedule", "api", "retry"]>;
|
|
2525
2656
|
readonly triggerRef: Schema.optional<Schema.String>;
|
|
2526
2657
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
2527
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
2658
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
2528
2659
|
/**
|
|
2529
2660
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
2530
2661
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -2687,6 +2818,170 @@ export declare const workspaceGatewayHeadersSchema: Schema.Struct<{
|
|
|
2687
2818
|
readonly "x-sealant-ssh-key-fingerprint": Schema.optional<Schema.String>;
|
|
2688
2819
|
}>;
|
|
2689
2820
|
export type WorkspaceGatewayHeaders = typeof workspaceGatewayHeadersSchema.Type;
|
|
2821
|
+
/**
|
|
2822
|
+
* Apply an updated network policy to a workspace ("Apply updated policy", §7.3): its pinned policy
|
|
2823
|
+
* and brokered secrets are replaced, and a running egress proxy takes them at once. Revocations
|
|
2824
|
+
* always win: a secret id or host revoked earlier stays refused whatever this policy lists, so a
|
|
2825
|
+
* secret is granted again only under a new `secretId`. `brokeredSecretValues` carries a value for
|
|
2826
|
+
* every `secretRef` the new secrets name (values already held are not sent again only when no
|
|
2827
|
+
* secret is listed).
|
|
2828
|
+
*/
|
|
2829
|
+
export declare const applyWorkspaceNetworkPolicyRequestSchema: Schema.Struct<{
|
|
2830
|
+
readonly ownerUserId: Schema.String;
|
|
2831
|
+
readonly networkPolicy: Schema.Struct<{
|
|
2832
|
+
readonly mode: Schema.Literals<readonly ["standard", "restricted"]>;
|
|
2833
|
+
readonly policyHash: Schema.String;
|
|
2834
|
+
readonly sourcePolicyId: Schema.optional<Schema.String>;
|
|
2835
|
+
readonly sourcePolicyRevision: Schema.optional<Schema.Int>;
|
|
2836
|
+
readonly requireVmIsolation: Schema.optional<Schema.Boolean>;
|
|
2837
|
+
readonly allowHosts: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2838
|
+
readonly host: Schema.String;
|
|
2839
|
+
readonly ports: Schema.optional<Schema.$Array<Schema.Int>>;
|
|
2840
|
+
readonly inspectTls: Schema.optional<Schema.Boolean>;
|
|
2841
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2842
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2843
|
+
}>>>;
|
|
2844
|
+
readonly allowMirrors: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2845
|
+
readonly name: Schema.Literals<readonly ["npm", "docker"]>;
|
|
2846
|
+
readonly host: Schema.String;
|
|
2847
|
+
readonly port: Schema.Int;
|
|
2848
|
+
}>>>;
|
|
2849
|
+
readonly allowResources: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2850
|
+
readonly name: Schema.String;
|
|
2851
|
+
readonly host: Schema.String;
|
|
2852
|
+
readonly port: Schema.Int;
|
|
2853
|
+
readonly guestIp: Schema.String;
|
|
2854
|
+
}>>>;
|
|
2855
|
+
}>;
|
|
2856
|
+
readonly brokeredSecrets: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2857
|
+
readonly secretId: Schema.String;
|
|
2858
|
+
readonly name: Schema.String;
|
|
2859
|
+
readonly placeholder: Schema.String;
|
|
2860
|
+
readonly secretRef: Schema.String;
|
|
2861
|
+
readonly headerName: Schema.String;
|
|
2862
|
+
readonly bindHosts: Schema.$Array<Schema.String>;
|
|
2863
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2864
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2865
|
+
}>>>;
|
|
2866
|
+
readonly brokeredSecretValues: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
|
|
2867
|
+
}>;
|
|
2868
|
+
export type ApplyWorkspaceNetworkPolicyRequest = typeof applyWorkspaceNetworkPolicyRequestSchema.Type;
|
|
2869
|
+
/**
|
|
2870
|
+
* What became of a policy update or a revocation on the workspace's running executor:
|
|
2871
|
+
*
|
|
2872
|
+
* - `enforced`: its egress proxy confirmed it (a revocation: after closing every matching stream).
|
|
2873
|
+
* - `pending`: it is stored, and the proxy has not confirmed it yet (it could not be reached). The
|
|
2874
|
+
* worker keeps pushing it; a revocation's unreachable proxy is killed, so nothing it revoked
|
|
2875
|
+
* stays reachable.
|
|
2876
|
+
* - `next-start`: it is stored, and no egress proxy runs for the workspace now (not running, or
|
|
2877
|
+
* running without one): it applies when the workspace next starts.
|
|
2878
|
+
*/
|
|
2879
|
+
export declare const workspaceNetworkPolicyEnforcementSchema: Schema.Literals<readonly ["enforced", "pending", "next-start"]>;
|
|
2880
|
+
export type WorkspaceNetworkPolicyEnforcement = typeof workspaceNetworkPolicyEnforcementSchema.Type;
|
|
2881
|
+
export declare const applyWorkspaceNetworkPolicyResponseSchema: Schema.Struct<{
|
|
2882
|
+
readonly workspaceId: Schema.String;
|
|
2883
|
+
readonly policyHash: Schema.String;
|
|
2884
|
+
/** The workspace's revocation watermark: every revocation up to it holds. */
|
|
2885
|
+
readonly revocationWatermark: Schema.Int;
|
|
2886
|
+
readonly enforcement: Schema.Literals<readonly ["enforced", "pending", "next-start"]>;
|
|
2887
|
+
/** Streams the proxy closed because the new policy no longer allows them (`enforced` only). */
|
|
2888
|
+
readonly closed: Schema.optional<Schema.Int>;
|
|
2889
|
+
}>;
|
|
2890
|
+
export type ApplyWorkspaceNetworkPolicyResponse = typeof applyWorkspaceNetworkPolicyResponseSchema.Type;
|
|
2891
|
+
/**
|
|
2892
|
+
* Revoke access on a workspace, durably: brokered secrets by id, hosts, or `all` grants. The
|
|
2893
|
+
* revocation is stored first, under a new revocation watermark, and holds for the workspace's life,
|
|
2894
|
+
* restarts included; a running egress proxy drops it and closes every matching stream before this
|
|
2895
|
+
* answers `enforced`. At least one of `secretIds`, `hosts` and `all`.
|
|
2896
|
+
*/
|
|
2897
|
+
export declare const revokeWorkspaceAccessRequestSchema: Schema.Struct<{
|
|
2898
|
+
readonly ownerUserId: Schema.String;
|
|
2899
|
+
readonly secretIds: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2900
|
+
readonly hosts: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2901
|
+
readonly all: Schema.optional<Schema.Boolean>;
|
|
2902
|
+
}>;
|
|
2903
|
+
export type RevokeWorkspaceAccessRequest = typeof revokeWorkspaceAccessRequestSchema.Type;
|
|
2904
|
+
export declare const revokeWorkspaceAccessResponseSchema: Schema.Struct<{
|
|
2905
|
+
readonly workspaceId: Schema.String;
|
|
2906
|
+
/** The watermark this revocation is stored under. */
|
|
2907
|
+
readonly revocationWatermark: Schema.Int;
|
|
2908
|
+
readonly enforcement: Schema.Literals<readonly ["enforced", "pending", "next-start"]>;
|
|
2909
|
+
/** Streams the proxy closed (`enforced` only). */
|
|
2910
|
+
readonly closed: Schema.optional<Schema.Int>;
|
|
2911
|
+
}>;
|
|
2912
|
+
export type RevokeWorkspaceAccessResponse = typeof revokeWorkspaceAccessResponseSchema.Type;
|
|
2913
|
+
export declare const getWorkspaceNetworkPolicyQuerySchema: Schema.Struct<{
|
|
2914
|
+
readonly ownerUserId: Schema.String;
|
|
2915
|
+
}>;
|
|
2916
|
+
export type GetWorkspaceNetworkPolicyQuery = typeof getWorkspaceNetworkPolicyQuerySchema.Type;
|
|
2917
|
+
/** One stored revocation. */
|
|
2918
|
+
export declare const workspaceAccessRevocationSchema: Schema.Struct<{
|
|
2919
|
+
readonly revocationWatermark: Schema.Int;
|
|
2920
|
+
readonly kind: Schema.Literals<readonly ["secret", "host", "all"]>;
|
|
2921
|
+
/** The secret id or host; absent for `all`. */
|
|
2922
|
+
readonly target: Schema.optional<Schema.String>;
|
|
2923
|
+
readonly revokedAt: Schema.String;
|
|
2924
|
+
}>;
|
|
2925
|
+
export type WorkspaceAccessRevocation = typeof workspaceAccessRevocationSchema.Type;
|
|
2926
|
+
/**
|
|
2927
|
+
* A workspace's pinned network policy, its brokered secrets (never their values), every revocation
|
|
2928
|
+
* it holds, and what its running egress proxy last confirmed. `networkPolicy` is absent for a
|
|
2929
|
+
* workspace created without one.
|
|
2930
|
+
*/
|
|
2931
|
+
export declare const workspaceNetworkPolicySchema: Schema.Struct<{
|
|
2932
|
+
readonly workspaceId: Schema.String;
|
|
2933
|
+
readonly networkPolicy: Schema.optional<Schema.Struct<{
|
|
2934
|
+
readonly mode: Schema.Literals<readonly ["standard", "restricted"]>;
|
|
2935
|
+
readonly policyHash: Schema.String;
|
|
2936
|
+
readonly sourcePolicyId: Schema.optional<Schema.String>;
|
|
2937
|
+
readonly sourcePolicyRevision: Schema.optional<Schema.Int>;
|
|
2938
|
+
readonly requireVmIsolation: Schema.optional<Schema.Boolean>;
|
|
2939
|
+
readonly allowHosts: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2940
|
+
readonly host: Schema.String;
|
|
2941
|
+
readonly ports: Schema.optional<Schema.$Array<Schema.Int>>;
|
|
2942
|
+
readonly inspectTls: Schema.optional<Schema.Boolean>;
|
|
2943
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2944
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2945
|
+
}>>>;
|
|
2946
|
+
readonly allowMirrors: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2947
|
+
readonly name: Schema.Literals<readonly ["npm", "docker"]>;
|
|
2948
|
+
readonly host: Schema.String;
|
|
2949
|
+
readonly port: Schema.Int;
|
|
2950
|
+
}>>>;
|
|
2951
|
+
readonly allowResources: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2952
|
+
readonly name: Schema.String;
|
|
2953
|
+
readonly host: Schema.String;
|
|
2954
|
+
readonly port: Schema.Int;
|
|
2955
|
+
readonly guestIp: Schema.String;
|
|
2956
|
+
}>>>;
|
|
2957
|
+
}>>;
|
|
2958
|
+
readonly brokeredSecrets: Schema.$Array<Schema.Struct<{
|
|
2959
|
+
readonly secretId: Schema.String;
|
|
2960
|
+
readonly name: Schema.String;
|
|
2961
|
+
readonly placeholder: Schema.String;
|
|
2962
|
+
readonly secretRef: Schema.String;
|
|
2963
|
+
readonly headerName: Schema.String;
|
|
2964
|
+
readonly bindHosts: Schema.$Array<Schema.String>;
|
|
2965
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2966
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2967
|
+
}>>;
|
|
2968
|
+
readonly revocationWatermark: Schema.Int;
|
|
2969
|
+
readonly revocations: Schema.$Array<Schema.Struct<{
|
|
2970
|
+
readonly revocationWatermark: Schema.Int;
|
|
2971
|
+
readonly kind: Schema.Literals<readonly ["secret", "host", "all"]>;
|
|
2972
|
+
/** The secret id or host; absent for `all`. */
|
|
2973
|
+
readonly target: Schema.optional<Schema.String>;
|
|
2974
|
+
readonly revokedAt: Schema.String;
|
|
2975
|
+
}>>;
|
|
2976
|
+
/** The current run's egress proxy; absent when the workspace has none. */
|
|
2977
|
+
readonly proxy: Schema.optional<Schema.Struct<{
|
|
2978
|
+
readonly runId: Schema.String;
|
|
2979
|
+
/** The policy hash and watermark the proxy last confirmed; absent before its first. */
|
|
2980
|
+
readonly confirmedPolicyHash: Schema.optional<Schema.String>;
|
|
2981
|
+
readonly confirmedRevocationWatermark: Schema.optional<Schema.Int>;
|
|
2982
|
+
}>>;
|
|
2983
|
+
}>;
|
|
2984
|
+
export type WorkspaceNetworkPolicy = typeof workspaceNetworkPolicySchema.Type;
|
|
2690
2985
|
declare const WorkspaceBadRequestError_base: Schema.Class<WorkspaceBadRequestError, Schema.TaggedStruct<"WorkspaceBadRequestError", {
|
|
2691
2986
|
readonly message: Schema.String;
|
|
2692
2987
|
}>, import("effect/Cause").YieldableError>;
|
|
@@ -2848,7 +3143,55 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
2848
3143
|
readonly recordDeletedAt: Schema.optional<Schema.String>;
|
|
2849
3144
|
readonly createdAt: Schema.String;
|
|
2850
3145
|
readonly updatedAt: Schema.String;
|
|
2851
|
-
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceForbiddenError | typeof WorkspaceNotFoundError | typeof WorkspaceConflictError | typeof WorkspaceBadGatewayError | typeof WorkspaceServiceUnavailableError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"
|
|
3146
|
+
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceForbiddenError | typeof WorkspaceNotFoundError | typeof WorkspaceConflictError | typeof WorkspaceBadGatewayError | typeof WorkspaceServiceUnavailableError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"applyWorkspaceNetworkPolicy", "PUT", "/:workspaceId/network-policy", Schema.toCodecStringTree<Schema.Struct<{
|
|
3147
|
+
readonly workspaceId: Schema.String;
|
|
3148
|
+
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
3149
|
+
readonly ownerUserId: Schema.String;
|
|
3150
|
+
readonly networkPolicy: Schema.Struct<{
|
|
3151
|
+
readonly mode: Schema.Literals<readonly ["standard", "restricted"]>;
|
|
3152
|
+
readonly policyHash: Schema.String;
|
|
3153
|
+
readonly sourcePolicyId: Schema.optional<Schema.String>;
|
|
3154
|
+
readonly sourcePolicyRevision: Schema.optional<Schema.Int>;
|
|
3155
|
+
readonly requireVmIsolation: Schema.optional<Schema.Boolean>;
|
|
3156
|
+
readonly allowHosts: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
3157
|
+
readonly host: Schema.String;
|
|
3158
|
+
readonly ports: Schema.optional<Schema.$Array<Schema.Int>>;
|
|
3159
|
+
readonly inspectTls: Schema.optional<Schema.Boolean>;
|
|
3160
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
3161
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
3162
|
+
}>>>;
|
|
3163
|
+
readonly allowMirrors: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
3164
|
+
readonly name: Schema.Literals<readonly ["npm", "docker"]>;
|
|
3165
|
+
readonly host: Schema.String;
|
|
3166
|
+
readonly port: Schema.Int;
|
|
3167
|
+
}>>>;
|
|
3168
|
+
readonly allowResources: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
3169
|
+
readonly name: Schema.String;
|
|
3170
|
+
readonly host: Schema.String;
|
|
3171
|
+
readonly port: Schema.Int;
|
|
3172
|
+
readonly guestIp: Schema.String;
|
|
3173
|
+
}>>>;
|
|
3174
|
+
}>;
|
|
3175
|
+
readonly brokeredSecrets: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
3176
|
+
readonly secretId: Schema.String;
|
|
3177
|
+
readonly name: Schema.String;
|
|
3178
|
+
readonly placeholder: Schema.String;
|
|
3179
|
+
readonly secretRef: Schema.String;
|
|
3180
|
+
readonly headerName: Schema.String;
|
|
3181
|
+
readonly bindHosts: Schema.$Array<Schema.String>;
|
|
3182
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
3183
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
3184
|
+
}>>>;
|
|
3185
|
+
readonly brokeredSecretValues: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
|
|
3186
|
+
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
3187
|
+
readonly workspaceId: Schema.String;
|
|
3188
|
+
readonly policyHash: Schema.String;
|
|
3189
|
+
/** The workspace's revocation watermark: every revocation up to it holds. */
|
|
3190
|
+
readonly revocationWatermark: Schema.Int;
|
|
3191
|
+
readonly enforcement: Schema.Literals<readonly ["enforced", "pending", "next-start"]>;
|
|
3192
|
+
/** Streams the proxy closed because the new policy no longer allows them (`enforced` only). */
|
|
3193
|
+
readonly closed: Schema.optional<Schema.Int>;
|
|
3194
|
+
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceRuntimeRequirementUnsupportedError | typeof WorkspaceNotFoundError | typeof WorkspaceServiceUnavailableError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"bindWorkspace", "POST", "/:workspaceId/bind", Schema.toCodecStringTree<Schema.Struct<{
|
|
2852
3195
|
readonly workspaceId: Schema.String;
|
|
2853
3196
|
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
2854
3197
|
readonly ownerUserId: Schema.String;
|
|
@@ -2914,6 +3257,13 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
2914
3257
|
readonly spec: Schema.Unknown;
|
|
2915
3258
|
readonly secretEnv: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
|
|
2916
3259
|
readonly captureToken: Schema.optional<Schema.String>;
|
|
3260
|
+
/**
|
|
3261
|
+
* The values of the spec's `brokeredSecrets`, keyed by `secretRef`: required for each one, and
|
|
3262
|
+
* refused without them. Sealed like `secretEnv`, but never delivered to the workspace: only its
|
|
3263
|
+
* egress proxy receives them. Kept sealed for the workspace's life, so a restart and a restarted
|
|
3264
|
+
* proxy get them again.
|
|
3265
|
+
*/
|
|
3266
|
+
readonly brokeredSecretValues: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
|
|
2917
3267
|
readonly ttlSeconds: Schema.optional<Schema.Int>;
|
|
2918
3268
|
/**
|
|
2919
3269
|
* Makes the create idempotent for this owner: a repeated create with the same key returns the
|
|
@@ -2955,7 +3305,7 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
2955
3305
|
* asynchronous); a replayed create carries the workspace's current one.
|
|
2956
3306
|
*/
|
|
2957
3307
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
2958
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
3308
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
2959
3309
|
/**
|
|
2960
3310
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
2961
3311
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -3217,7 +3567,7 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
3217
3567
|
readonly repository: Schema.optional<Schema.String>;
|
|
3218
3568
|
readonly tag: Schema.optional<Schema.String>;
|
|
3219
3569
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
3220
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
3570
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
3221
3571
|
/**
|
|
3222
3572
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
3223
3573
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -3560,7 +3910,63 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
3560
3910
|
readonly workspaceId: Schema.optional<Schema.String>;
|
|
3561
3911
|
readonly runId: Schema.optional<Schema.String>;
|
|
3562
3912
|
readonly launchId: Schema.optional<Schema.String>;
|
|
3563
|
-
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"
|
|
3913
|
+
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"getWorkspaceNetworkPolicy", "GET", "/:workspaceId/network-policy", Schema.toCodecStringTree<Schema.Struct<{
|
|
3914
|
+
readonly workspaceId: Schema.String;
|
|
3915
|
+
}>>, Schema.toCodecStringTree<Schema.Struct<{
|
|
3916
|
+
readonly ownerUserId: Schema.String;
|
|
3917
|
+
}>>, never, never, Schema.toCodecJson<Schema.Struct<{
|
|
3918
|
+
readonly workspaceId: Schema.String;
|
|
3919
|
+
readonly networkPolicy: Schema.optional<Schema.Struct<{
|
|
3920
|
+
readonly mode: Schema.Literals<readonly ["standard", "restricted"]>;
|
|
3921
|
+
readonly policyHash: Schema.String;
|
|
3922
|
+
readonly sourcePolicyId: Schema.optional<Schema.String>;
|
|
3923
|
+
readonly sourcePolicyRevision: Schema.optional<Schema.Int>;
|
|
3924
|
+
readonly requireVmIsolation: Schema.optional<Schema.Boolean>;
|
|
3925
|
+
readonly allowHosts: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
3926
|
+
readonly host: Schema.String;
|
|
3927
|
+
readonly ports: Schema.optional<Schema.$Array<Schema.Int>>;
|
|
3928
|
+
readonly inspectTls: Schema.optional<Schema.Boolean>;
|
|
3929
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
3930
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
3931
|
+
}>>>;
|
|
3932
|
+
readonly allowMirrors: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
3933
|
+
readonly name: Schema.Literals<readonly ["npm", "docker"]>;
|
|
3934
|
+
readonly host: Schema.String;
|
|
3935
|
+
readonly port: Schema.Int;
|
|
3936
|
+
}>>>;
|
|
3937
|
+
readonly allowResources: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
3938
|
+
readonly name: Schema.String;
|
|
3939
|
+
readonly host: Schema.String;
|
|
3940
|
+
readonly port: Schema.Int;
|
|
3941
|
+
readonly guestIp: Schema.String;
|
|
3942
|
+
}>>>;
|
|
3943
|
+
}>>;
|
|
3944
|
+
readonly brokeredSecrets: Schema.$Array<Schema.Struct<{
|
|
3945
|
+
readonly secretId: Schema.String;
|
|
3946
|
+
readonly name: Schema.String;
|
|
3947
|
+
readonly placeholder: Schema.String;
|
|
3948
|
+
readonly secretRef: Schema.String;
|
|
3949
|
+
readonly headerName: Schema.String;
|
|
3950
|
+
readonly bindHosts: Schema.$Array<Schema.String>;
|
|
3951
|
+
readonly methods: Schema.optional<Schema.$Array<Schema.String>>;
|
|
3952
|
+
readonly pathPrefixes: Schema.optional<Schema.$Array<Schema.String>>;
|
|
3953
|
+
}>>;
|
|
3954
|
+
readonly revocationWatermark: Schema.Int;
|
|
3955
|
+
readonly revocations: Schema.$Array<Schema.Struct<{
|
|
3956
|
+
readonly revocationWatermark: Schema.Int;
|
|
3957
|
+
readonly kind: Schema.Literals<readonly ["secret", "host", "all"]>;
|
|
3958
|
+
/** The secret id or host; absent for `all`. */
|
|
3959
|
+
readonly target: Schema.optional<Schema.String>;
|
|
3960
|
+
readonly revokedAt: Schema.String;
|
|
3961
|
+
}>>;
|
|
3962
|
+
/** The current run's egress proxy; absent when the workspace has none. */
|
|
3963
|
+
readonly proxy: Schema.optional<Schema.Struct<{
|
|
3964
|
+
readonly runId: Schema.String;
|
|
3965
|
+
/** The policy hash and watermark the proxy last confirmed; absent before its first. */
|
|
3966
|
+
readonly confirmedPolicyHash: Schema.optional<Schema.String>;
|
|
3967
|
+
readonly confirmedRevocationWatermark: Schema.optional<Schema.Int>;
|
|
3968
|
+
}>>;
|
|
3969
|
+
}>>, Schema.toCodecJson<typeof WorkspaceNotFoundError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"getWorkspaceSshTarget", "GET", "/:workspaceId/ssh-target", Schema.toCodecStringTree<Schema.Struct<{
|
|
3564
3970
|
readonly workspaceId: Schema.String;
|
|
3565
3971
|
}>>, never, never, Schema.toCodecStringTree<Schema.Struct<{
|
|
3566
3972
|
readonly "x-sealant-gateway-token": Schema.optional<Schema.String>;
|
|
@@ -3571,7 +3977,7 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
3571
3977
|
readonly workspaceId: Schema.String;
|
|
3572
3978
|
readonly attemptId: Schema.String;
|
|
3573
3979
|
readonly runtime: Schema.Struct<{
|
|
3574
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
3980
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
3575
3981
|
readonly resourceId: Schema.String;
|
|
3576
3982
|
readonly reference: Schema.String;
|
|
3577
3983
|
readonly status: Schema.Literals<readonly ["pending", "running", "ready", "failed", "stopped"]>;
|
|
@@ -3706,7 +4112,7 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
3706
4112
|
readonly triggerType: Schema.Literals<readonly ["manual", "schedule", "api", "retry"]>;
|
|
3707
4113
|
readonly triggerRef: Schema.optional<Schema.String>;
|
|
3708
4114
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
3709
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
4115
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
3710
4116
|
/**
|
|
3711
4117
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
3712
4118
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -3915,9 +4321,9 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
3915
4321
|
readonly data: Schema.optional<Schema.Unknown>;
|
|
3916
4322
|
}>>;
|
|
3917
4323
|
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceNotFoundError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"listWorkspaceRuntimes", "GET", "/runtimes", never, never, never, never, Schema.toCodecJson<Schema.Struct<{
|
|
3918
|
-
readonly default: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
4324
|
+
readonly default: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
3919
4325
|
readonly runtimes: Schema.$Array<Schema.Struct<{
|
|
3920
|
-
readonly runtime: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
4326
|
+
readonly runtime: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
3921
4327
|
/** The managed OS families that run on this runtime (`target.os.family`). */
|
|
3922
4328
|
readonly os: Schema.Struct<{
|
|
3923
4329
|
readonly ubuntu: Schema.Union<readonly [Schema.Struct<{
|
|
@@ -4020,6 +4426,41 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
4020
4426
|
readonly charged: Schema.Boolean;
|
|
4021
4427
|
readonly message: Schema.String;
|
|
4022
4428
|
}>;
|
|
4429
|
+
/**
|
|
4430
|
+
* What the runtime enforces of a network policy (`spec.networkPolicy`, `spec.brokeredSecrets`). A
|
|
4431
|
+
* create that asks for an unsupported item is refused, never run with less. Absent from control
|
|
4432
|
+
* planes that predate network policies.
|
|
4433
|
+
*/
|
|
4434
|
+
readonly networkPolicy: Schema.optional<Schema.Struct<{
|
|
4435
|
+
/** The workspace in its own VM (`networkPolicy.requireVmIsolation`). */
|
|
4436
|
+
readonly vmIsolation: Schema.Union<readonly [Schema.Struct<{
|
|
4437
|
+
readonly supported: Schema.Literal<true>;
|
|
4438
|
+
}>, Schema.Struct<{
|
|
4439
|
+
readonly supported: Schema.Literal<false>;
|
|
4440
|
+
readonly message: Schema.String;
|
|
4441
|
+
}>]>;
|
|
4442
|
+
/** `networkPolicy.mode: "restricted"`. */
|
|
4443
|
+
readonly restricted: Schema.Union<readonly [Schema.Struct<{
|
|
4444
|
+
readonly supported: Schema.Literal<true>;
|
|
4445
|
+
}>, Schema.Struct<{
|
|
4446
|
+
readonly supported: Schema.Literal<false>;
|
|
4447
|
+
readonly message: Schema.String;
|
|
4448
|
+
}>]>;
|
|
4449
|
+
/** `restricted` together with Docker inside the workspace. */
|
|
4450
|
+
readonly restrictedWithDocker: Schema.Union<readonly [Schema.Struct<{
|
|
4451
|
+
readonly supported: Schema.Literal<true>;
|
|
4452
|
+
}>, Schema.Struct<{
|
|
4453
|
+
readonly supported: Schema.Literal<false>;
|
|
4454
|
+
readonly message: Schema.String;
|
|
4455
|
+
}>]>;
|
|
4456
|
+
/** Any `brokeredSecrets`, whatever the mode. */
|
|
4457
|
+
readonly brokeredSecrets: Schema.Union<readonly [Schema.Struct<{
|
|
4458
|
+
readonly supported: Schema.Literal<true>;
|
|
4459
|
+
}>, Schema.Struct<{
|
|
4460
|
+
readonly supported: Schema.Literal<false>;
|
|
4461
|
+
readonly message: Schema.String;
|
|
4462
|
+
}>]>;
|
|
4463
|
+
}>>;
|
|
4023
4464
|
}>>;
|
|
4024
4465
|
}>>, Schema.toCodecJson<typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"listWorkspaces", "GET", "/", never, Schema.toCodecStringTree<Schema.Struct<{
|
|
4025
4466
|
readonly ownerUserId: Schema.String;
|
|
@@ -4037,7 +4478,7 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
4037
4478
|
readonly repository: Schema.optional<Schema.String>;
|
|
4038
4479
|
readonly tag: Schema.optional<Schema.String>;
|
|
4039
4480
|
readonly runtime: Schema.optional<Schema.Struct<{
|
|
4040
|
-
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat"]>;
|
|
4481
|
+
readonly adapter: Schema.Literals<readonly ["docker", "k8s", "k3s", "cloudflare", "microvm", "boat", "host-vm"]>;
|
|
4041
4482
|
/**
|
|
4042
4483
|
* The executor's identity on its runtime: the Docker container id, the Pod name, the MicroVM
|
|
4043
4484
|
* id. This is the id a caller records at launch and names in a stop's `completion`.
|
|
@@ -4442,7 +4883,21 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
4442
4883
|
/** The new attempt driving the fresh launch. */
|
|
4443
4884
|
readonly runId: Schema.String;
|
|
4444
4885
|
readonly status: Schema.Literals<readonly ["queued", "running", "ready", "failed", "cancelled", "stopped", "retained"]>;
|
|
4445
|
-
}>>, Schema.toCodecJson<typeof BudgetExceededError | typeof WorkspaceBadRequestError | typeof WorkspaceRuntimeEnvReferencesUnsupportedError | typeof WorkspaceRuntimeRequirementUnsupportedError | typeof WorkspaceDockerServiceUnsupportedError | typeof WorkspaceNotFoundError | typeof WorkspaceConflictError | typeof WorkspaceBadGatewayError | typeof WorkspaceServiceUnavailableError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"
|
|
4886
|
+
}>>, Schema.toCodecJson<typeof BudgetExceededError | typeof WorkspaceBadRequestError | typeof WorkspaceRuntimeEnvReferencesUnsupportedError | typeof WorkspaceRuntimeRequirementUnsupportedError | typeof WorkspaceDockerServiceUnsupportedError | typeof WorkspaceNotFoundError | typeof WorkspaceConflictError | typeof WorkspaceBadGatewayError | typeof WorkspaceServiceUnavailableError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"revokeWorkspaceAccess", "POST", "/:workspaceId/network-policy/revocations", Schema.toCodecStringTree<Schema.Struct<{
|
|
4887
|
+
readonly workspaceId: Schema.String;
|
|
4888
|
+
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
4889
|
+
readonly ownerUserId: Schema.String;
|
|
4890
|
+
readonly secretIds: Schema.optional<Schema.$Array<Schema.String>>;
|
|
4891
|
+
readonly hosts: Schema.optional<Schema.$Array<Schema.String>>;
|
|
4892
|
+
readonly all: Schema.optional<Schema.Boolean>;
|
|
4893
|
+
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
4894
|
+
readonly workspaceId: Schema.String;
|
|
4895
|
+
/** The watermark this revocation is stored under. */
|
|
4896
|
+
readonly revocationWatermark: Schema.Int;
|
|
4897
|
+
readonly enforcement: Schema.Literals<readonly ["enforced", "pending", "next-start"]>;
|
|
4898
|
+
/** Streams the proxy closed (`enforced` only). */
|
|
4899
|
+
readonly closed: Schema.optional<Schema.Int>;
|
|
4900
|
+
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceRuntimeRequirementUnsupportedError | typeof WorkspaceNotFoundError | typeof WorkspaceServiceUnavailableError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"stopWorkspace", "POST", "/:workspaceId/stop", Schema.toCodecStringTree<Schema.Struct<{
|
|
4446
4901
|
readonly workspaceId: Schema.String;
|
|
4447
4902
|
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
4448
4903
|
readonly ownerUserId: Schema.String;
|