sandcovery 0.6.0 → 0.6.1

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/README.md CHANGED
@@ -63,7 +63,7 @@ sandcovery sandboxes destroy "$id" --yes
63
63
  - `sandcovery login` shows a URL and a code to approve in a browser signed in to Sandcovery, then saves a login, readable only by you, that commands send when neither `--token` nor `SANDCOVERY_API_KEY` is set. `sandcovery logout` revokes it and deletes it.
64
64
  - `sandcovery sandboxes exec` streams the command's output and exits with the command's exit code.
65
65
  - `sandcovery docker <args>` runs `docker <args>` in a sandbox on a provider that runs Docker, streams its output, and exits with its exit code, so a computer with no Docker can build and run containers. Later `sandcovery docker` commands reuse that sandbox until its TTL ends. Before Docker runs, it copies the local files the command reads into the sandbox at the same absolute paths, up to 100 MiB packed, and runs Docker in the same working directory there: build contexts without what `.dockerignore` leaves out, bind mount sources, env files, the files `cp`, `load -i`, and `import` read, and a Compose project's files, build contexts, and bind mounts. It copies only paths under your home folder or the working directory. When stdin is not a terminal and Docker reads it, as with `login --password-stdin` or `load`, it hands stdin to Docker, and when stdout is not a terminal and Docker writes an archive there, as with `save`, the archive arrives byte for byte. Docker gets a terminal wherever yours is one, so `docker run -it`, `docker exec -it`, and `docker attach` work, and a command runs until it exits.
66
- - `sandcovery-docker <args>` does the same in the same sandbox, takes Docker's arguments alone, and adds nothing to Docker's stdout or stderr, so `alias docker=sandcovery-docker` runs `docker` in the sandbox. It reads the key from `SANDCOVERY_API_KEY` or the saved login. Docker's environment variables are read in the sandbox, and a port a container publishes is reachable only inside the sandbox.
66
+ - `sandcovery-docker <args>` does the same in the same sandbox, takes Docker's arguments alone, and adds nothing to Docker's stdout or stderr, so `alias docker=sandcovery-docker` runs `docker` in the sandbox. It reads the key from `SANDCOVERY_API_KEY` or the saved login. The variables Docker reads come from your computer's environment, such as a name given to `-e` with no value, `DOCKER_DEFAULT_PLATFORM`, and the shell variables a Compose file names, and the command sends the sandbox only those. A TCP port a container publishes answers on the same address and port of your computer.
67
67
  - `sandcovery kubectl <args>` runs your own `kubectl <args>` against a one-node Kubernetes cluster in a sandbox on Freestyle, or on boxd when Freestyle cannot create it, and exits with its exit code. The first command that reaches the cluster starts it, which takes a few minutes, and later commands reuse it. It stops 15 minutes after the last command that reached it ends, or at its TTL, whichever comes first, and a command that keeps running, such as `port-forward` or `logs -f`, keeps it running. `kubectl` must be on `PATH` and runs on your computer, so local files, `port-forward`, `exec -it`, and `logs -f` work as they do with a local cluster. `completion`, `config`, `version --client`, and `--help` start no cluster.
68
68
  - `sandcovery-kubectl <args>` does the same on the same cluster, takes `kubectl`'s arguments alone, and adds nothing to `kubectl`'s stdout or stderr, so `alias kubectl=sandcovery-kubectl` runs `kubectl` on the sandbox's cluster. It reads the key from `SANDCOVERY_API_KEY` or the saved login.
69
69
  - `--json` prints one JSON document on stdout, and every failure prints a JSON error with a stable `reason` on stderr.
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { t as start } from "../start-Dg7sRQ28.mjs";
2
+ import { t as start } from "../start-aOWo5B3M.mjs";
3
3
  // src/cli/index.ts
4
4
  await start({ argv: process.argv.slice(2) });
5
5
  export {};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { t as start } from "../start-Dg7sRQ28.mjs";
2
+ import { t as start } from "../start-aOWo5B3M.mjs";
3
3
  // src/cli/sandcovery-docker.ts
4
4
  await start({
5
5
  argv: ["docker", ...process.argv.slice(2)],
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { t as start } from "../start-Dg7sRQ28.mjs";
2
+ import { t as start } from "../start-aOWo5B3M.mjs";
3
3
  // src/cli/sandcovery-kubectl.ts
4
4
  await start({
5
5
  argv: ["kubectl", ...process.argv.slice(2)],
@@ -1,6 +1,6 @@
1
1
  import { $ as CurrentRedactedNames, $n as merge$1, $t as timeoutOrElse, An as exitInterrupt$1, Ar as toJson, At as interrupt$1, B as makeFilter, Bn as TaggedError, Br as isString, Bt as provide, C as decodeUnknownEffect, Cn as hasInterrupts, Cr as makePrimitive, Ct as fail$2, D as encodeSync, Dn as andThen, Dr as BaseProto, Dt as forever, E as decodeUnknownSync, Er as setStackTraceLimit, Et as fnUntraced, Fn as succeed, Fr as symbol$1, Ft as onExit$1, G as CurrentRedactedNames$1, Gn as of, Gr as identity, Gt as runPromise, H as optionalKey, Hn as seconds, Hr as constTrue, Ht as provideService, In as suspend$2, Ir as hasProperty, It as onExitPrimitive, J as redactUrl, Jn as isSuccess, Jt as succeed$1, K as empty$2, Kn as getSuccess, Kr as pipeArguments, Kt as runSync, Ln as sync, Lr as isNotNull, Lt as onInterrupt, M as isGreaterThan, Mn as exitZipRight, Mr as redact, Mt as mapError, Nn as fiberInterrupt, Nr as symbol, Nt as matchCauseEffect, O as fromJsonString, On as callback, Or as Class, Ot as forkIn, P as isMaxCodePoints, Pn as makeLatchUnsafe, Pr as random, Pt as onError, Q as unwrap, Qn as getOrUndefined$1, R as isSchemaError, Rn as TracerTimingEnabled$1, Rr as isNotNullish, Rt as orElseSucceed, S as decodeTo, Sn as done, Sr as isExit, St as ensuring$2, T as decodeUnknownResult, Tn as squash, Tr as getStackTraceLimit, Tt as flatMap, Ur as constVoid, V as optional, Vr as constFalse, Vt as provideContext, W as makeFormatterStandardSchemaV1, Wn as toSeconds, Wr as dual, Wt as runFork, X as toString, Xn as Reference, Xt as sync$1, Y as setAll$1, Yn as try_, Yt as suspend$3, Z as fromBody, Zn as Service$1, Zt as tap$1, _ as String$1, _n as close, _r as args, _t as catchIf, an as void_, at as remove, b as Unknown, bn as fail$3, br as exitFailCause, bt as contextWith, c as Json, cn as withParentSpan, cr as isSome, ct as fromSetCookie, dn as catchDone, dr as match, dt as as$1, en as tryPromise, er as exists$1, et as empty$3, fn as doneExitFromCause, fr as none, ft as asVoid, g as Record, gn as addFinalizerExit, gr as PipeInspectableProto, hn as addFinalizer, hr as Done, ht as catchCause, in as useSpan, ir as getOrNull, it as merge$2, jn as exitVoid, jr as format, jt as map, k as is$1, kr as NodeInspectSymbol, kt as gen, l as Literal, lr as liftThrowable, m as NullOr, mn as effect, mr as toArray, mt as callback$1, nn as uninterruptibleMask, nr as fromNullishOr, nt as fromRecordUnsafe, o as FiniteFromString, on as whileLoop, or as getOrUndefined, ot as set, p as NonEmptyString, pn as isDoneCause, pr as some, pt as cached, q as fromInput, qn as isFailure, qt as sleep, r as DateFromString, rn as updateContext, rr as getOrElse, rt as isRedactedName, s as Int, sn as withFiber$1, sr as isNone, st as setAll, t as ArraySchema, tn as try_$1, tr as flatMap$1, tt as fromInput$1, u as Literals, ur as map$1, ut as andThen$1, v as Struct, vn as forkUnsafe, vr as evaluate, vt as catchTag, w as decodeUnknownOption, wn as isTimeoutError, wr as withFiber, wt as failCause$1, xn as TimeoutError, xr as exitSucceed, y as Union, yn as makeUnsafe$1, yr as exitFail, yt as context, zn as DisablePropagation, zr as isPropertyKey, zt as promise } from "./Schema-CoX0a2_o.mjs";
2
- import { C as enabledVariable, F as rerunArgv, I as valuesOf$1, O as flagOf, Q as CliFailure, R as ellipsis, S as writePrivateFile, U as escapeUnprintable, Y as isDigits, Z as isWordCharacter, _ as formatMoney, a as RELAY_PORT, at as holdCluster, c as onPath, ct as Clock, d as BIN, f as CLEARABLE, g as formatCount, h as counted, i as forwarderSocket, j as lastValue, m as PROBLEM_REPORT_MAX, n as attachForwarder, nt as Canceled, o as RELAY_SOURCE, q as consistsOf, rt as IDLE_MS, s as v7, st as noop, tt as usageFailure, u as shimsOf, v as formatPercent, x as withFileLock, y as version } from "./port-forwarder-Du1VlKxg.mjs";
3
- import { A as NO_MARKUP_TERMS, C as AUTO_TOP_UP_THRESHOLD_MIN_MICRO_USD, D as ENTERPRISE_PLAN, E as CREDIT_PURCHASE_MIN_MICRO_USD, G as CiJobId, J as KeySecret, K as CredentialId, L as CreateSandboxRequest, M as thresholdBelowTopUp, N as ApiError, O as FREE_PLAN, Q as UsageShareId, R as Port, S as AUTO_TOP_UP_THRESHOLD_MAX_MICRO_USD, T as CREDIT_PURCHASE_MAX_MICRO_USD, V as ProviderSort, W as ApiKeyId, X as Provider, Y as ProcessId, Z as SandboxId, _ as KeyKind, a as USAGE_SHARE_FIGURES, b as CredentialFields, c as EstimateRequest, d as UsagePeriod, f as API_PREFIX, g as CreateKeyRequest, i as ShareToken, j as creditsAfterFeeMicroUsd, k as MICRO_USD_PER_DOLLAR, l as MONTH_TEXT, m as SANDCOVERY_ORIGIN, n as CreateUsageShareRequest, o as UsageShareFigure, p as LocalPath, q as KeyId, r as DEFAULT_SHARED_FIGURES, s as CalendarDay, t as Sandcovery, u as MonthlyCostQuery, v as SpendLimit, x as GitHubId, y as UpdateKeyRequest, z as SandboxStatus } from "./src-lrpT0LG_.mjs";
2
+ import { C as enabledVariable, F as rerunArgv, I as valuesOf$1, O as flagOf, Q as CliFailure, R as ellipsis, S as writePrivateFile, U as escapeUnprintable, Y as isDigits, Z as isWordCharacter, _ as formatMoney, a as RELAY_PORT, at as holdCluster, c as onPath, ct as Clock, d as BIN, f as CLEARABLE, g as formatCount, h as counted, i as forwarderSocket, j as lastValue, m as PROBLEM_REPORT_MAX, n as attachForwarder, nt as Canceled, o as RELAY_SOURCE, q as consistsOf, rt as IDLE_MS, s as v7, st as noop, tt as usageFailure, u as shimsOf, v as formatPercent, x as withFileLock, y as version } from "./port-forwarder-DxnuUTsW.mjs";
3
+ import { A as NO_MARKUP_TERMS, C as AUTO_TOP_UP_THRESHOLD_MIN_MICRO_USD, D as ENTERPRISE_PLAN, E as CREDIT_PURCHASE_MIN_MICRO_USD, G as CiJobId, J as KeySecret, K as CredentialId, L as CreateSandboxRequest, M as thresholdBelowTopUp, N as ApiError, O as FREE_PLAN, Q as UsageShareId, R as Port, S as AUTO_TOP_UP_THRESHOLD_MAX_MICRO_USD, T as CREDIT_PURCHASE_MAX_MICRO_USD, V as ProviderSort, W as ApiKeyId, X as Provider, Y as ProcessId, Z as SandboxId, _ as KeyKind, a as USAGE_SHARE_FIGURES, b as CredentialFields, c as EstimateRequest, d as UsagePeriod, f as API_PREFIX, g as CreateKeyRequest, i as ShareToken, j as creditsAfterFeeMicroUsd, k as MICRO_USD_PER_DOLLAR, l as MONTH_TEXT, m as SANDCOVERY_ORIGIN, n as CreateUsageShareRequest, o as UsageShareFigure, p as LocalPath, q as KeyId, r as DEFAULT_SHARED_FIGURES, s as CalendarDay, t as Sandcovery, u as MonthlyCostQuery, v as SpendLimit, x as GitHubId, y as UpdateKeyRequest, z as SandboxStatus } from "./src-BqfeIyqj.mjs";
4
4
  import { createRequire } from "node:module";
5
5
  import { spawn } from "node:child_process";
6
6
  import { createHash, randomBytes } from "node:crypto";
@@ -11992,7 +11992,7 @@ var require_public_api = /* @__PURE__ */ __commonJSMin(((exports) => {
11992
11992
  exports.parseDocument = parseDocument;
11993
11993
  exports.stringify = stringify;
11994
11994
  }));
11995
- // src/cli/commands/compose.ts
11995
+ // src/cli/commands/environment.ts
11996
11996
  var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
11997
11997
  var composer = require_composer();
11998
11998
  var Document = require_Document();
@@ -12039,6 +12039,102 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
12039
12039
  exports.visit = visit.visit;
12040
12040
  exports.visitAsync = visit.visitAsync;
12041
12041
  })))();
12042
+ const ASSIGNED = "SANDCOVERY_DOCKER_ENV_";
12043
+ const UNSET = "SANDCOVERY_DOCKER_UNSET_";
12044
+ const DOLLAR$1 = "$";
12045
+ const DOCKER_CONFIG = `DOCKER_CONFIG="${DOLLAR$1}{DOCKER_CONFIG:-$HOME/.docker}"`;
12046
+ const CLIENT_VARIABLES = [
12047
+ "BUILDKIT_COLORS",
12048
+ "BUILDKIT_PROGRESS",
12049
+ "BUILDKIT_TTY_LOG_LINES",
12050
+ "BUILDX_BAKE_DISABLE_VARS_ENV_LOOKUP",
12051
+ "BUILDX_BAKE_FILE",
12052
+ "BUILDX_BAKE_FILE_RELATIVE_PATHS",
12053
+ "BUILDX_BAKE_FILE_SEPARATOR",
12054
+ "BUILDX_BAKE_GIT_ADVICE",
12055
+ "BUILDX_BAKE_GIT_AUTH_HEADER",
12056
+ "BUILDX_BAKE_GIT_AUTH_TOKEN",
12057
+ "BUILDX_CPU_PROFILE",
12058
+ "BUILDX_EXPERIMENTAL",
12059
+ "BUILDX_GIT_CHECK_DIRTY",
12060
+ "BUILDX_GIT_INFO",
12061
+ "BUILDX_GIT_LABELS",
12062
+ "BUILDX_MEM_PROFILE",
12063
+ "BUILDX_METADATA_PROVENANCE",
12064
+ "BUILDX_METADATA_WARNINGS",
12065
+ "BUILDX_NO_DEFAULT_ATTESTATIONS",
12066
+ "BUILDX_NO_DEFAULT_LOAD",
12067
+ "BUILDX_NO_DEFAULT_OCI_ARTIFACT",
12068
+ "BUILDX_SEND_GIT_QUERY_AS_INPUT",
12069
+ "COMPOSE_ANSI",
12070
+ "COMPOSE_CONVERT_WINDOWS_PATHS",
12071
+ "COMPOSE_DISABLE_ENV_FILE",
12072
+ "COMPOSE_ENV_FILES",
12073
+ "COMPOSE_EXPERIMENTAL",
12074
+ "COMPOSE_FILE",
12075
+ "COMPOSE_IGNORE_ORPHANS",
12076
+ "COMPOSE_MENU",
12077
+ "COMPOSE_PARALLEL_LIMIT",
12078
+ "COMPOSE_PATH_SEPARATOR",
12079
+ "COMPOSE_PROFILES",
12080
+ "COMPOSE_PROGRESS",
12081
+ "COMPOSE_PROJECT_NAME",
12082
+ "COMPOSE_REMOVE_ORPHANS",
12083
+ "COMPOSE_STATUS_STDOUT",
12084
+ "DOCKER_API_VERSION",
12085
+ "DOCKER_CUSTOM_HEADERS",
12086
+ "DOCKER_DEFAULT_PLATFORM",
12087
+ "DOCKER_HIDE_LEGACY_COMMANDS",
12088
+ "EXPERIMENTAL_BUILDKIT_SOURCE_POLICY",
12089
+ "NO_COLOR"
12090
+ ];
12091
+ const LOCAL_ONLY = /* @__PURE__ */ new Set([
12092
+ "BUILDKIT_HOST",
12093
+ "BUILDX_BAKE_GIT_SSH",
12094
+ "BUILDX_BUILDER",
12095
+ "BUILDX_CONFIG",
12096
+ "DOCKER_CERT_PATH",
12097
+ "DOCKER_CONFIG",
12098
+ "DOCKER_CONTEXT",
12099
+ "DOCKER_HOST",
12100
+ "DOCKER_TLS",
12101
+ "DOCKER_TLS_VERIFY",
12102
+ "HTTPS_PROXY",
12103
+ "HTTP_PROXY",
12104
+ "NO_PROXY"
12105
+ ]);
12106
+ const listOf = ({ separator, value }) => value === void 0 || value === "" ? [] : value.split(separator);
12107
+ const carriedEnv = ({ named, shell }) => {
12108
+ const client = CLIENT_VARIABLES.filter((name) => shell[name] !== void 0);
12109
+ const names = [.../* @__PURE__ */ new Set([...client, ...named])].filter((name) => name !== "" && !name.includes("=") && !LOCAL_ONLY.has(name));
12110
+ const assigned = names.flatMap((name) => {
12111
+ const value = shell[name];
12112
+ return value === void 0 ? [] : [`${name}=${value}`];
12113
+ });
12114
+ const unset = names.filter((name) => shell[name] === void 0);
12115
+ return Object.fromEntries([...assigned.map((entry, index) => [`${ASSIGNED}${String(index)}`, entry]), ...unset.map((name, index) => [`${UNSET}${String(index)}`, name])]);
12116
+ };
12117
+ const reference = (carrier) => `"${DOLLAR$1}${carrier}"`;
12118
+ const sudoCall = (env) => {
12119
+ const carriers = Object.keys(env);
12120
+ return carriers.length === 0 ? "sudo -n" : `sudo -n --preserve-env=${carriers.join(",")}`;
12121
+ };
12122
+ const dockerCall = (env) => {
12123
+ const carriers = Object.keys(env);
12124
+ if (carriers.length === 0) return "docker";
12125
+ const unset = carriers.flatMap((carrier) => carrier.startsWith(UNSET) ? [`-u ${reference(carrier)}`] : []);
12126
+ const assigned = carriers.flatMap((carrier) => carrier.startsWith(ASSIGNED) ? [reference(carrier)] : []);
12127
+ return [
12128
+ "env",
12129
+ ...carriers.map((carrier) => `-u ${carrier}`),
12130
+ ...unset,
12131
+ "--",
12132
+ DOCKER_CONFIG,
12133
+ ...assigned,
12134
+ "\"$(command -v docker)\""
12135
+ ].join(" ");
12136
+ };
12137
+ // src/cli/commands/compose.ts
12042
12138
  const COMPOSE_FILES = [
12043
12139
  "compose.yaml",
12044
12140
  "compose.yml",
@@ -12066,7 +12162,7 @@ const VALUE_FLAGS = /* @__PURE__ */ new Set([
12066
12162
  ]);
12067
12163
  const FILE_FLAGS$1 = /* @__PURE__ */ new Set(["--file", "-f"]);
12068
12164
  const DIRECTORY_FLAGS = /* @__PURE__ */ new Set(["--project-directory", "--workdir"]);
12069
- const ENV_FILE_FLAGS = /* @__PURE__ */ new Set(["--env-file"]);
12165
+ const ENV_FILE_FLAGS$1 = /* @__PURE__ */ new Set(["--env-file"]);
12070
12166
  const READING_SUBCOMMANDS = /* @__PURE__ */ new Set([
12071
12167
  "attach",
12072
12168
  "config",
@@ -12096,6 +12192,8 @@ const READING_SUBCOMMANDS = /* @__PURE__ */ new Set([
12096
12192
  ]);
12097
12193
  const COMPOSE_FILE_VARIABLE = "COMPOSE_FILE";
12098
12194
  const PATH_SEPARATOR_VARIABLE = "COMPOSE_PATH_SEPARATOR";
12195
+ const ENV_FILES_VARIABLE = "COMPOSE_ENV_FILES";
12196
+ const ENV_FILES_SEPARATOR = ",";
12099
12197
  const DOT_ENV = ".env";
12100
12198
  const DOCKERFILE$1 = "Dockerfile";
12101
12199
  const EXPORT_PREFIX = "export ";
@@ -12106,8 +12204,11 @@ const Texts = Union([String$1, ArraySchema(String$1)]);
12106
12204
  const Paths = Union([String$1, ArraySchema(Union([String$1, Struct({ path: String$1 })]))]);
12107
12205
  const ContextList = ArraySchema(String$1);
12108
12206
  const AdditionalContexts = Union([ContextList, Record(String$1, String$1)]);
12207
+ const MappingList = ArraySchema(Unknown);
12208
+ const Mapping = Union([MappingList, Record(String$1, Unknown)]);
12109
12209
  const Build = Union([String$1, Struct({
12110
12210
  additional_contexts: optionalKey(AdditionalContexts),
12211
+ args: optionalKey(Mapping),
12111
12212
  context: optionalKey(String$1),
12112
12213
  dockerfile: optionalKey(String$1),
12113
12214
  dockerfile_inline: optionalKey(String$1)
@@ -12116,10 +12217,14 @@ const Volume = Union([String$1, Struct({
12116
12217
  source: optionalKey(String$1),
12117
12218
  type: optionalKey(String$1)
12118
12219
  })]);
12119
- const FileSource = Struct({ file: optionalKey(String$1) });
12220
+ const FileSource = Struct({
12221
+ environment: optionalKey(String$1),
12222
+ file: optionalKey(String$1)
12223
+ });
12120
12224
  const Service = Struct({
12121
12225
  build: optionalKey(Build),
12122
12226
  env_file: optionalKey(Paths),
12227
+ environment: optionalKey(Mapping),
12123
12228
  extends: optionalKey(Union([String$1, FileSource])),
12124
12229
  label_file: optionalKey(Texts),
12125
12230
  volumes: optionalKey(ArraySchema(Volume))
@@ -12137,6 +12242,7 @@ const Model = Struct({
12137
12242
  });
12138
12243
  const decodeModel = decodeUnknownSync(Model);
12139
12244
  const isContextList = is$1(ContextList);
12245
+ const isMappingList = is$1(MappingList);
12140
12246
  const readText$2 = liftThrowable((file) => fs.readFileSync(file, "utf-8"));
12141
12247
  const statOf = liftThrowable((file) => fs.statSync(file));
12142
12248
  const isFile$1 = (file) => exists$1(statOf(file), (stat) => stat.isFile());
@@ -12152,6 +12258,26 @@ const nameAt = (text, start) => {
12152
12258
  })) end += 1;
12153
12259
  return text.slice(start, end);
12154
12260
  };
12261
+ const referencedNames = (text) => {
12262
+ const names = [];
12263
+ let index = text.indexOf("$");
12264
+ while (index !== -1) {
12265
+ const next = text.charAt(index + 1);
12266
+ const start = next === "{" ? index + 2 : index + 1;
12267
+ const name = next === "$" ? "" : nameAt(text, start);
12268
+ if (name !== "") names.push(name);
12269
+ index = text.indexOf("$", next === "$" ? index + 2 : start);
12270
+ }
12271
+ return names;
12272
+ };
12273
+ const namesIn = (document) => {
12274
+ const names = [];
12275
+ const scalarNames = (key, node) => {
12276
+ if (key !== "key" && isString(node.value)) names.push(...referencedNames(node.value));
12277
+ };
12278
+ (0, import_dist.visit)(document, { Scalar: scalarNames });
12279
+ return names;
12280
+ };
12155
12281
  const closingBrace = (text, start) => {
12156
12282
  let depth = 0;
12157
12283
  let index = start;
@@ -12231,34 +12357,45 @@ const withoutComment = (value) => {
12231
12357
  const starts = [value.indexOf(" #"), value.indexOf(" #")].filter((index) => index >= 0);
12232
12358
  return starts.length === 0 ? value : value.slice(0, Math.min(...starts));
12233
12359
  };
12360
+ const interpolatedText = (raw) => {
12361
+ if (raw.startsWith("'")) return;
12362
+ return (raw.startsWith("\"") ? doubleQuoted(raw) : withoutComment(raw)).trimEnd();
12363
+ };
12234
12364
  const dotenvValue = ({ env, raw }) => {
12235
- if (raw.startsWith("'")) {
12236
- const end = raw.indexOf("'", 1);
12237
- return end === -1 ? raw.slice(1) : raw.slice(1, end);
12238
- }
12239
- const text = raw.startsWith("\"") ? doubleQuoted(raw) : withoutComment(raw);
12240
- return interpolated({
12365
+ const text = interpolatedText(raw);
12366
+ if (text !== void 0) return interpolated({
12241
12367
  env,
12242
- text: text.trimEnd()
12368
+ text
12243
12369
  });
12244
- };
12370
+ const end = raw.indexOf("'", 1);
12371
+ return end === -1 ? raw.slice(1) : raw.slice(1, end);
12372
+ };
12373
+ const dotenvLines = (text) => text.split("\n").flatMap((line) => {
12374
+ const trimmed = line.trim();
12375
+ const assignment = trimmed.startsWith(EXPORT_PREFIX) ? trimmed.slice(7).trimStart() : trimmed;
12376
+ const equals = assignment.indexOf("=");
12377
+ if (assignment === "" || equals === 0 || assignment.startsWith("#")) return [];
12378
+ return equals === -1 ? [{
12379
+ key: assignment,
12380
+ raw: null
12381
+ }] : [{
12382
+ key: assignment.slice(0, equals).trim(),
12383
+ raw: assignment.slice(equals + 1).trim()
12384
+ }];
12385
+ });
12245
12386
  const dotenvEntries = ({ env, text }) => {
12246
12387
  const entries = /* @__PURE__ */ new Map();
12247
- for (const line of text.split("\n")) {
12248
- const trimmed = line.trim();
12249
- const assignment = trimmed.startsWith(EXPORT_PREFIX) ? trimmed.slice(7).trimStart() : trimmed;
12250
- const equals = assignment.indexOf("=");
12251
- if (equals > 0 && !assignment.startsWith("#")) {
12252
- const key = assignment.slice(0, equals).trim();
12253
- const raw = assignment.slice(equals + 1).trim();
12254
- entries.set(key, dotenvValue({
12255
- env: new Map([...entries, ...env]),
12256
- raw
12257
- }));
12258
- }
12259
- }
12388
+ for (const { key, raw } of dotenvLines(text)) if (raw !== null) entries.set(key, dotenvValue({
12389
+ env: new Map([...entries, ...env]),
12390
+ raw
12391
+ }));
12260
12392
  return entries;
12261
12393
  };
12394
+ const dotenvNames = (text) => dotenvLines(text).flatMap(({ key, raw }) => {
12395
+ if (raw === null) return [key];
12396
+ const interpolates = interpolatedText(raw);
12397
+ return interpolates === void 0 ? [] : referencedNames(interpolates);
12398
+ });
12262
12399
  const withDotenv = ({ env, files }) => {
12263
12400
  let current = env;
12264
12401
  for (const file of files) for (const text of toArray(readText$2(file))) current = new Map([...dotenvEntries({
@@ -12272,7 +12409,7 @@ const fromCwd = (cwd, texts) => texts.flatMap((text) => resolved({
12272
12409
  directory: cwd,
12273
12410
  text
12274
12411
  }));
12275
- const localPaths$1 = ({ location, values }) => values.flatMap((value) => resolved({
12412
+ const localPaths = ({ location, values }) => values.flatMap((value) => resolved({
12276
12413
  directory: location.directory,
12277
12414
  text: interpolated({
12278
12415
  env: location.env,
@@ -12299,12 +12436,20 @@ const additionalContexts = (contexts) => {
12299
12436
  if (contexts === void 0) return [];
12300
12437
  return isContextList(contexts) ? contexts.map(afterEquals$1) : Object.values(contexts);
12301
12438
  };
12439
+ const bareNames$1 = (mapping) => {
12440
+ if (mapping === void 0) return [];
12441
+ if (isMappingList(mapping)) return mapping.filter((entry) => isString(entry) && !entry.includes("="));
12442
+ return Object.entries(mapping).flatMap(([name, value]) => value === null ? [name] : []);
12443
+ };
12444
+ const addNames = (found, names) => {
12445
+ for (const name of names) found.names.add(name);
12446
+ };
12302
12447
  const addContext = ({ context, dockerfile, found, location }) => {
12303
12448
  for (const directory of localContexts({
12304
12449
  location,
12305
12450
  values: [context]
12306
12451
  })) {
12307
- const [file] = localPaths$1({
12452
+ const [file] = localPaths({
12308
12453
  location: {
12309
12454
  ...location,
12310
12455
  directory
@@ -12333,6 +12478,7 @@ const addBuild = ({ build, found, location }) => {
12333
12478
  location,
12334
12479
  values: extras
12335
12480
  })) found.mounted.add(directory);
12481
+ addNames(found, bareNames$1(build.args));
12336
12482
  const inline = build.dockerfile_inline !== void 0;
12337
12483
  addContext({
12338
12484
  context: build.context ?? ".",
@@ -12366,15 +12512,21 @@ const addService = ({ found, load, location, service }) => {
12366
12512
  directory: location.directory,
12367
12513
  text
12368
12514
  })) found.mounted.add(source);
12369
- const read = [...pathsOf(service.env_file), ...textsOf(service.label_file)];
12370
- for (const file of localPaths$1({
12515
+ addNames(found, bareNames$1(service.environment));
12516
+ const envFiles = localPaths({
12517
+ location,
12518
+ values: pathsOf(service.env_file)
12519
+ });
12520
+ const labelFiles = localPaths({
12371
12521
  location,
12372
- values: read
12373
- })) found.read.add(file);
12522
+ values: textsOf(service.label_file)
12523
+ });
12524
+ for (const file of envFiles) found.envFiles.add(file);
12525
+ for (const file of [...envFiles, ...labelFiles]) found.read.add(file);
12374
12526
  const parent = service.extends;
12375
12527
  if (parent === void 0 || isString(parent)) return;
12376
12528
  const values = parent.file === void 0 ? [] : [parent.file];
12377
- for (const file of localPaths$1({
12529
+ for (const file of localPaths({
12378
12530
  location,
12379
12531
  values
12380
12532
  })) load({
@@ -12388,22 +12540,25 @@ const addService = ({ found, load, location, service }) => {
12388
12540
  };
12389
12541
  const addInclude = ({ found, include, load, location }) => {
12390
12542
  const named = isString(include) ? include : include.path;
12391
- const files = localPaths$1({
12543
+ const files = localPaths({
12392
12544
  location,
12393
12545
  values: textsOf(named)
12394
12546
  });
12395
12547
  const [first] = files;
12396
12548
  if (first === void 0) return;
12397
12549
  const options = isString(include) ? void 0 : include;
12398
- const [directory = path.dirname(first)] = localPaths$1({
12550
+ const [directory = path.dirname(first)] = localPaths({
12399
12551
  location,
12400
12552
  values: textsOf(options?.project_directory)
12401
12553
  });
12402
- const envFiles = options?.env_file === void 0 ? [path.join(directory, DOT_ENV)] : localPaths$1({
12554
+ const envFiles = options?.env_file === void 0 ? [path.join(directory, DOT_ENV)] : localPaths({
12403
12555
  location,
12404
12556
  values: pathsOf(options.env_file)
12405
12557
  });
12406
- for (const file of envFiles) found.read.add(file);
12558
+ for (const file of envFiles) {
12559
+ found.envFiles.add(file);
12560
+ found.read.add(file);
12561
+ }
12407
12562
  const env = withDotenv({
12408
12563
  env: location.env,
12409
12564
  files: envFiles
@@ -12417,18 +12572,16 @@ const addInclude = ({ found, include, load, location }) => {
12417
12572
  }
12418
12573
  });
12419
12574
  };
12420
- const modelsIn = (text) => {
12421
- return (0, import_dist.parseAllDocuments)(text, { merge: true }).filter((parsed) => parsed.errors.length === 0).flatMap((parsed) => toArray(liftThrowable(() => decodeModel(parsed.toJS()))()));
12422
- };
12575
+ const documentsIn = (text) => (0, import_dist.parseAllDocuments)(text, { merge: true }).filter((parsed) => parsed.errors.length === 0);
12576
+ const decodedModel = liftThrowable(decodeModel);
12577
+ const modelsOf = (document) => toArray(decodedModel(document.toJS()));
12423
12578
  const loadFile = ({ file, found, location }) => {
12424
12579
  if (found.loaded.has(file)) return;
12425
12580
  found.loaded.add(file);
12426
12581
  found.read.add(file);
12427
- const models = match(readText$2(file), {
12428
- onNone: () => [],
12429
- onSome: modelsIn
12430
- });
12431
- for (const model of models) {
12582
+ const documents = toArray(readText$2(file)).flatMap(documentsIn);
12583
+ addNames(found, documents.flatMap(namesIn));
12584
+ for (const model of documents.flatMap(modelsOf)) {
12432
12585
  const services = Object.values(model.services ?? {});
12433
12586
  const sources = [...Object.values(model.configs ?? {}), ...Object.values(model.secrets ?? {})];
12434
12587
  for (const include of model.include ?? []) addInclude({
@@ -12443,8 +12596,9 @@ const loadFile = ({ file, found, location }) => {
12443
12596
  location,
12444
12597
  service
12445
12598
  });
12599
+ addNames(found, sources.flatMap((source) => textsOf(source.environment)));
12446
12600
  const values = sources.flatMap((source) => textsOf(source.file));
12447
- for (const source of localPaths$1({
12601
+ for (const source of localPaths({
12448
12602
  location,
12449
12603
  values
12450
12604
  })) found.mounted.add(source);
@@ -12478,7 +12632,7 @@ const optionsOf = (words) => {
12478
12632
  }
12479
12633
  const valuesOf = (names) => flags.flatMap(({ flag, value }) => names.has(flag) ? [value] : []);
12480
12634
  return {
12481
- envFiles: valuesOf(ENV_FILE_FLAGS),
12635
+ envFiles: valuesOf(ENV_FILE_FLAGS$1),
12482
12636
  files: valuesOf(FILE_FLAGS$1),
12483
12637
  projectDirectories: valuesOf(DIRECTORY_FLAGS),
12484
12638
  subcommand
@@ -12495,15 +12649,16 @@ const defaultFiles = (directory) => {
12495
12649
  return parent === directory ? [] : defaultFiles(parent);
12496
12650
  };
12497
12651
  const fromVariable = ({ cwd, env }) => {
12498
- const value = env.get(COMPOSE_FILE_VARIABLE);
12499
- if (value === void 0 || value === "") return;
12500
- const separator = env.get(PATH_SEPARATOR_VARIABLE) ?? path.delimiter;
12501
- return fromCwd(cwd, value.split(separator));
12652
+ const files = listOf({
12653
+ separator: env.get(PATH_SEPARATOR_VARIABLE) ?? path.delimiter,
12654
+ value: env.get(COMPOSE_FILE_VARIABLE)
12655
+ });
12656
+ return files.length === 0 ? void 0 : fromCwd(cwd, files);
12502
12657
  };
12503
- const composeFiles = ({ base, cwd, envFiles, files }) => {
12658
+ const composeFiles = ({ base, cwd, envFiles, files, shell }) => {
12504
12659
  if (files.length > 0) return fromCwd(cwd, files.filter((file) => file !== "-"));
12505
12660
  const env = withDotenv({
12506
- env: /* @__PURE__ */ new Map(),
12661
+ env: shell,
12507
12662
  files: envFiles
12508
12663
  });
12509
12664
  return fromVariable({
@@ -12520,17 +12675,23 @@ const wholePath = (file) => ({
12520
12675
  kind: "whole",
12521
12676
  path: file
12522
12677
  });
12523
- const composePaths = ({ cwd, words }) => {
12678
+ const composeReads = ({ cwd, shell, words }) => {
12524
12679
  const options = optionsOf(words);
12525
12680
  const [base = cwd] = fromCwd(cwd, options.projectDirectories.slice(-1));
12526
- const named = fromCwd(cwd, options.envFiles);
12527
- const explicit = options.envFiles.length > 0;
12681
+ const listed = options.envFiles.length > 0 ? options.envFiles : listOf({
12682
+ separator: ENV_FILES_SEPARATOR,
12683
+ value: shell[ENV_FILES_VARIABLE]
12684
+ });
12685
+ const named = fromCwd(cwd, listed);
12686
+ const explicit = listed.length > 0;
12528
12687
  const firstEnvFiles = explicit ? named : [path.join(base, DOT_ENV)];
12688
+ const variables = new Map(Object.entries(shell).flatMap(([name, value]) => value === void 0 ? [] : [[name, value]]));
12529
12689
  const files = composeFiles({
12530
12690
  base,
12531
12691
  cwd,
12532
12692
  envFiles: firstEnvFiles,
12533
- files: options.files
12693
+ files: options.files,
12694
+ shell: variables
12534
12695
  });
12535
12696
  const [first] = files;
12536
12697
  const fileDirectory = first === void 0 ? base : path.dirname(first);
@@ -12538,13 +12699,15 @@ const composePaths = ({ cwd, words }) => {
12538
12699
  const projectEnv = path.join(directory, DOT_ENV);
12539
12700
  const envFiles = explicit ? named : [...firstEnvFiles, projectEnv];
12540
12701
  const env = withDotenv({
12541
- env: /* @__PURE__ */ new Map(),
12702
+ env: variables,
12542
12703
  files: envFiles
12543
12704
  });
12544
12705
  const found = {
12545
12706
  contexts: [],
12707
+ envFiles: new Set(envFiles),
12546
12708
  loaded: /* @__PURE__ */ new Set(),
12547
12709
  mounted: /* @__PURE__ */ new Set(),
12710
+ names: /* @__PURE__ */ new Set(),
12548
12711
  read: new Set(envFiles)
12549
12712
  };
12550
12713
  for (const file of files) loadFile({
@@ -12555,16 +12718,24 @@ const composePaths = ({ cwd, words }) => {
12555
12718
  env
12556
12719
  }
12557
12720
  });
12721
+ const fromEnvFiles = [...found.envFiles].flatMap((file) => toArray(readText$2(file)).flatMap(dotenvNames));
12722
+ const names = [...found.names, ...fromEnvFiles];
12558
12723
  const { subcommand } = options;
12559
12724
  const sends = subcommand !== void 0 && !READING_SUBCOMMANDS.has(subcommand);
12560
12725
  const read = [...found.read].map(wholePath);
12561
- if (!sends) return read;
12726
+ if (!sends) return {
12727
+ names,
12728
+ paths: read
12729
+ };
12562
12730
  const mounted = [...found.mounted].map(wholePath);
12563
- return [
12564
- ...read,
12565
- ...mounted,
12566
- ...found.contexts.map(contextPath)
12567
- ];
12731
+ return {
12732
+ names,
12733
+ paths: [
12734
+ ...read,
12735
+ ...mounted,
12736
+ ...found.contexts.map(contextPath)
12737
+ ]
12738
+ };
12568
12739
  };
12569
12740
  // src/cli/commands/processes.ts
12570
12741
  const START_ACTION$1 = "start the process";
@@ -16568,7 +16739,13 @@ const BUILD_CONTEXT_FLAGS = /* @__PURE__ */ new Set(["--build-context"]);
16568
16739
  const SECRET_FLAGS = /* @__PURE__ */ new Set(["--secret"]);
16569
16740
  const VOLUME_FLAGS = /* @__PURE__ */ new Set(["--volume", "-v"]);
16570
16741
  const MOUNT_FLAGS = /* @__PURE__ */ new Set(["--mount"]);
16571
- const RUN_FILE_FLAGS = /* @__PURE__ */ new Set(["--env-file", "--label-file"]);
16742
+ const ENV_FILE_FLAGS = /* @__PURE__ */ new Set(["--env-file"]);
16743
+ const RUN_FILE_FLAGS = /* @__PURE__ */ new Set([...ENV_FILE_FLAGS, "--label-file"]);
16744
+ const ENV_FLAGS = /* @__PURE__ */ new Set(["--env", "-e"]);
16745
+ const BUILD_ARG_FLAGS = /* @__PURE__ */ new Set(["--build-arg"]);
16746
+ const SOURCE_POLICY_VARIABLE = "EXPERIMENTAL_BUILDKIT_SOURCE_POLICY";
16747
+ const BAKE_FILE_VARIABLE = "BUILDX_BAKE_FILE";
16748
+ const BAKE_FILE_SEPARATOR_VARIABLE = "BUILDX_BAKE_FILE_SEPARATOR";
16572
16749
  const INPUT_FLAGS = /* @__PURE__ */ new Set(["--input", "-i"]);
16573
16750
  const decodeSandboxes = decodeUnknownOption(fromJsonString(Record(String$1, SandboxId)));
16574
16751
  const decodeDockerSandboxes = decodeUnknownOption(fromJsonString(Record(String$1, Struct({
@@ -16841,14 +17018,28 @@ const dockerfileOf = ({ cwd, directory, file }) => {
16841
17018
  if (file === void 0) return path.join(directory, DOCKERFILE);
16842
17019
  return file === "-" ? void 0 : path.resolve(cwd, file);
16843
17020
  };
16844
- const buildPaths = ({ cwd, words }) => {
17021
+ const secretVariable = (secret) => {
17022
+ const fields = csvFields(secret);
17023
+ const type = fields.get("type");
17024
+ const source = fields.get("src") ?? fields.get("source");
17025
+ const typed = type === "env" ? source : void 0;
17026
+ const name = fields.get("env") ?? typed ?? fields.get("id");
17027
+ return type === "file" || name === void 0 ? [] : [name];
17028
+ };
17029
+ const bareNames = (values) => values.filter((value) => !value.includes("="));
17030
+ const policyPaths = ({ cwd, shell }) => wholePaths({
17031
+ cwd,
17032
+ values: [shell[SOURCE_POLICY_VARIABLE] ?? ""]
17033
+ });
17034
+ const buildPaths = (input) => {
17035
+ const { cwd, words } = input;
16845
17036
  const { flags, operands } = parsedWords({
16846
17037
  stopAtOperand: false,
16847
17038
  switches: BUILD_SWITCHES,
16848
17039
  words
16849
17040
  });
16850
17041
  const context = operands.at(-1);
16851
- if (context === void 0 || context === "-" || isRemote(context)) return [];
17042
+ if (context === void 0 || context === "-" || isRemote(context)) return policyPaths(input);
16852
17043
  const directory = path.resolve(cwd, context);
16853
17044
  const file = valuesOf(flags, FILE_FLAGS).at(-1);
16854
17045
  const dockerfile = dockerfileOf({
@@ -16858,14 +17049,38 @@ const buildPaths = ({ cwd, words }) => {
16858
17049
  });
16859
17050
  const extras = valuesOf(flags, BUILD_CONTEXT_FLAGS).map(afterEquals);
16860
17051
  const secrets = valuesOf(flags, SECRET_FLAGS).flatMap(secretSource);
16861
- return [{
16862
- dockerfile,
16863
- kind: "context",
16864
- path: directory
16865
- }, ...wholePaths({
16866
- cwd,
16867
- values: [...extras, ...secrets]
16868
- })];
17052
+ return [
17053
+ {
17054
+ dockerfile,
17055
+ kind: "context",
17056
+ path: directory
17057
+ },
17058
+ ...wholePaths({
17059
+ cwd,
17060
+ values: [...extras, ...secrets]
17061
+ }),
17062
+ ...policyPaths(input)
17063
+ ];
17064
+ };
17065
+ const buildNames = ({ words }) => {
17066
+ const { flags } = parsedWords({
17067
+ stopAtOperand: false,
17068
+ switches: BUILD_SWITCHES,
17069
+ words
17070
+ });
17071
+ return [...bareNames(valuesOf(flags, BUILD_ARG_FLAGS)), ...valuesOf(flags, SECRET_FLAGS).flatMap(secretVariable)];
17072
+ };
17073
+ const envFileNames = (text) => text.split("\n").flatMap((line) => {
17074
+ const entry = (line.endsWith("\r") ? line.slice(0, -1) : line).trimStart();
17075
+ return entry === "" || entry.startsWith("#") || entry.includes("=") ? [] : [entry];
17076
+ });
17077
+ const runNames = ({ cwd, words }) => {
17078
+ const { flags } = parsedWords({
17079
+ stopAtOperand: true,
17080
+ switches: RUN_SWITCHES,
17081
+ words
17082
+ });
17083
+ return [...valuesOf(flags, ENV_FILE_FLAGS).flatMap((file) => toArray(readText(path.resolve(cwd, file)))).flatMap(envFileNames), ...bareNames(valuesOf(flags, ENV_FLAGS))];
16869
17084
  };
16870
17085
  const runPaths = ({ cwd, words }) => {
16871
17086
  const { flags } = parsedWords({
@@ -16921,31 +17136,59 @@ const importPaths = ({ cwd, words }) => {
16921
17136
  values: operands.slice(0, 1)
16922
17137
  });
16923
17138
  };
16924
- const bakePaths = ({ cwd }) => [{
16925
- dockerfile: path.join(cwd, DOCKERFILE),
16926
- kind: "context",
16927
- path: cwd
16928
- }];
17139
+ const bakePaths = (input) => {
17140
+ const { cwd, shell } = input;
17141
+ const separator = shell[BAKE_FILE_SEPARATOR_VARIABLE] ?? "";
17142
+ const files = listOf({
17143
+ separator: separator === "" ? path.delimiter : separator,
17144
+ value: shell[BAKE_FILE_VARIABLE]
17145
+ });
17146
+ return [
17147
+ {
17148
+ dockerfile: path.join(cwd, DOCKERFILE),
17149
+ kind: "context",
17150
+ path: cwd
17151
+ },
17152
+ ...wholePaths({
17153
+ cwd,
17154
+ values: files
17155
+ }),
17156
+ ...policyPaths(input)
17157
+ ];
17158
+ };
16929
17159
  const PATH_COLLECTORS = /* @__PURE__ */ new Map([
16930
17160
  ["bake", bakePaths],
16931
17161
  ["build", buildPaths],
16932
17162
  ["cp", cpPaths],
16933
17163
  ["create", runPaths],
17164
+ ["exec", runPaths],
16934
17165
  ["import", importPaths],
16935
17166
  ["load", loadPaths],
16936
17167
  ["run", runPaths]
16937
17168
  ]);
16938
- const localPaths = ({ args, cwd }) => {
17169
+ const NAME_COLLECTORS = /* @__PURE__ */ new Map([
17170
+ ["build", buildNames],
17171
+ ["create", runNames],
17172
+ ["exec", runNames],
17173
+ ["run", runNames]
17174
+ ]);
17175
+ const localReads = ({ args, cwd, shell }) => {
16939
17176
  const [command, ...rest] = commandWords(args);
16940
- if (command === COMPOSE) return composePaths({
17177
+ if (command === COMPOSE) return composeReads({
16941
17178
  cwd,
17179
+ shell,
16942
17180
  words: rest
16943
17181
  });
16944
17182
  const { name, words } = dockerCommand(args);
16945
- return PATH_COLLECTORS.get(name)?.({
17183
+ const input = {
16946
17184
  cwd,
17185
+ shell,
16947
17186
  words
16948
- }) ?? [];
17187
+ };
17188
+ return {
17189
+ names: NAME_COLLECTORS.get(name)?.(input) ?? [],
17190
+ paths: PATH_COLLECTORS.get(name)?.(input) ?? []
17191
+ };
16949
17192
  };
16950
17193
  const runningSandbox = async ({ action, context, id }) => {
16951
17194
  try {
@@ -17130,9 +17373,10 @@ const dockerSandbox = async (context) => {
17130
17373
  });
17131
17374
  return sandbox;
17132
17375
  };
17133
- const remoteCommand = ({ args, prefix }) => {
17134
- const script = `${prefix} && exec docker ${args.map(quoted).join(" ")}`;
17135
- return `s= && [ "$(id -u)" -eq 0 ] || s='sudo -n' && exec $s sh -c ${quoted(script)}`;
17376
+ const remoteCommand = ({ args, env, prefix }) => {
17377
+ const words = args.map(quoted).join(" ");
17378
+ const script = `${prefix} && exec ${dockerCall(env)} ${words}`;
17379
+ return `s= && [ "$(id -u)" -eq 0 ] || s='${sudoCall(env)}' && exec $s sh -c ${quoted(script)}`;
17136
17380
  };
17137
17381
  const terminalLike = (context) => {
17138
17382
  const streams = {
@@ -17161,9 +17405,11 @@ const dockerRun = async (context) => {
17161
17405
  sync: false
17162
17406
  });
17163
17407
  const live = new Set(Object.values(savedDockerSandboxes(sandboxesFile(context))).map((saved) => saved.id));
17164
- const paths = localPaths({
17408
+ const shell = process.env;
17409
+ const { names, paths } = localReads({
17165
17410
  args,
17166
- cwd
17411
+ cwd,
17412
+ shell
17167
17413
  });
17168
17414
  const prefix = await syncCommand({
17169
17415
  context,
@@ -17172,11 +17418,20 @@ const dockerRun = async (context) => {
17172
17418
  live,
17173
17419
  paths
17174
17420
  });
17421
+ const env = carriedEnv({
17422
+ named: names,
17423
+ shell
17424
+ });
17175
17425
  const terminal = terminalLike(context);
17176
- const run = { command: remoteCommand({
17426
+ const script = remoteCommand({
17177
17427
  args,
17428
+ env,
17178
17429
  prefix
17179
- }) };
17430
+ });
17431
+ const run = Object.keys(env).length === 0 ? { command: script } : {
17432
+ command: script,
17433
+ env
17434
+ };
17180
17435
  const exitCode = await runAttached({
17181
17436
  context,
17182
17437
  forwards: context.mode.stdin.tty || readsStdin(command),
package/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { $ as FileList, $t as SandboxList, An as XPostRequest, B as DetachedExec, C as CiJob, Ct as Pricing, Dt as Process, Et as ProblemReportRequest, I as CredentialFields, It as ProviderCredential, J as ExecEvent, K as EstimateList, L as CreditCheckout, Lt as ProviderCredentialList, M as CreateSandboxRequest, Mt as ProviderBoard, N as CreateUsageShareRequest, Nt as ProviderBoardEntry, On as XAccountLink, Ot as ProcessRequest, P as CreatedKey, Pt as ProviderCatalog, R as CreditPurchaseRequest, S as CiInstallationList, Sn as UsageShareList, St as PortPreview, T as CiJobList, V as DetachedExecRequest, X as ExecResult, Xt as Sandbox, Y as ExecRequest, Z as FileEntry, _n as Usage, bn as UsageShare, c as AutoTopUpRequest, dn as Stats, en as SandboxStatus, gn as UpdateKeyRequest, ht as MonthlyCostList, i as ActivityList, j as CreateKeyRequest, jt as Provider, kn as XAccountStatus, o as AutoTopUp, on as Snapshot, pt as LiveUsage, q as EstimateRequest, rn as SharedUsage, s as AutoTopUpChange, st as Key, u as Billing, ut as KeyList, vt as Offer, wn as UsageTotals } from "./types-C7lGEXT5.mjs";
1
+ import { $ as FileList, An as XAccountStatus, B as DetachedExec, C as CiJob, Cn as UsageShareList, Ct as PortPreview, Dt as ProblemReportRequest, Ft as ProviderCatalog, I as CredentialFields, J as ExecEvent, K as EstimateList, L as CreditCheckout, Lt as ProviderCredential, M as CreateSandboxRequest, Mt as Provider, N as CreateUsageShareRequest, Nt as ProviderBoard, Ot as Process, P as CreatedKey, Pt as ProviderBoardEntry, R as CreditPurchaseRequest, Rt as ProviderCredentialList, S as CiInstallationList, T as CiJobList, Tn as UsageTotals, V as DetachedExecRequest, X as ExecResult, Y as ExecRequest, Z as FileEntry, Zt as Sandbox, _n as UpdateKeyRequest, c as AutoTopUpRequest, en as SandboxList, fn as Stats, ht as MonthlyCostList, i as ActivityList, in as SharedUsage, j as CreateKeyRequest, jn as XPostRequest, kn as XAccountLink, kt as ProcessRequest, o as AutoTopUp, pt as LiveUsage, q as EstimateRequest, s as AutoTopUpChange, sn as Snapshot, st as Key, tn as SandboxStatus, u as Billing, ut as KeyList, vn as Usage, vt as Offer, wt as Pricing, xn as UsageShare } from "./types-C4amb2QE.mjs";
2
2
  interface ProcessExit {
3
3
  readonly code: number;
4
4
  readonly signal: string | null;
package/dist/index.mjs CHANGED
@@ -1 +1 @@
1
- export { t as Sandcovery } from "./src-lrpT0LG_.mjs";
1
+ export { t as Sandcovery } from "./src-BqfeIyqj.mjs";
@@ -1,5 +1,5 @@
1
1
  import { Bn as TaggedError, Br as isString, Ct as fail, E as decodeUnknownSync, En as ClockRef, Hn as seconds, Ir as hasProperty, Jn as isSuccess, O as fromJsonString, Qt as tapError, Tt as flatMap, Un as toMillis, Ut as retry, Vn as millis, Xt as sync, Yn as try_, Yt as suspend, _ as String$1, an as void_, ar as getOrThrowWith, cr as isSome, g as Record, gt as catchDefect, h as Number$1, kn as currentTimeMillis$1, ln as spaced, lt as acquireUseRelease, m as NullOr, n as Boolean, rr as getOrElse, sr as isNone, t as ArraySchema, u as Literals, un as upTo, ur as map, v as Struct, vt as catchTag, w as decodeUnknownOption, xt as die } from "./Schema-CoX0a2_o.mjs";
2
- import { A as NO_MARKUP_TERMS, B as DEFAULT_SLUG, C as AUTO_TOP_UP_THRESHOLD_MIN_MICRO_USD, E as CREDIT_PURCHASE_MIN_MICRO_USD, F as Unauthorized, H as Forbidden, I as NotFound, P as Unsupported, S as AUTO_TOP_UP_THRESHOLD_MAX_MICRO_USD, T as CREDIT_PURCHASE_MAX_MICRO_USD, U as Conflict, V as ProviderSort, _ as KeyKind, h as SANDCOVERY_X_HANDLE, k as MICRO_USD_PER_DOLLAR, l as MONTH_TEXT, t as Sandcovery, v as SpendLimit, w as CARD_FEE_TERMS, z as SandboxStatus } from "./src-lrpT0LG_.mjs";
2
+ import { A as NO_MARKUP_TERMS, B as DEFAULT_SLUG, C as AUTO_TOP_UP_THRESHOLD_MIN_MICRO_USD, E as CREDIT_PURCHASE_MIN_MICRO_USD, F as Unauthorized, H as Forbidden, I as NotFound, P as Unsupported, S as AUTO_TOP_UP_THRESHOLD_MAX_MICRO_USD, T as CREDIT_PURCHASE_MAX_MICRO_USD, U as Conflict, V as ProviderSort, _ as KeyKind, h as SANDCOVERY_X_HANDLE, k as MICRO_USD_PER_DOLLAR, l as MONTH_TEXT, t as Sandcovery, v as SpendLimit, w as CARD_FEE_TERMS, z as SandboxStatus } from "./src-BqfeIyqj.mjs";
3
3
  import { WebSocket } from "node:http";
4
4
  import net from "node:net";
5
5
  import readline from "node:readline";
@@ -1123,7 +1123,7 @@ const withFileLock = ({ bin, file, work }) => {
1123
1123
  }), () => work, (own) => removeIf(lock, sameAs(own)));
1124
1124
  };
1125
1125
  // package.json
1126
- var version = "0.6.0";
1126
+ var version = "0.6.1";
1127
1127
  // ../format/src/display.ts
1128
1128
  const LOCALE = "en-US";
1129
1129
  const UTC = "UTC";
@@ -2016,8 +2016,9 @@ const docker = {
2016
2016
  notes: [
2017
2017
  "Runs the Docker CLI in a sandbox with every word after docker, streams its stdout and stderr to this terminal's, and exits with its exit code.",
2018
2018
  "The first command starts a sandbox on a provider that runs Docker, as Sandcovery CI runners do, and later commands reuse it until it ends at its TTL, so images, containers, and volumes carry over between commands. sandcovery sandboxes destroy ends it sooner.",
2019
- "Before docker runs, the command copies the local files it reads into the sandbox at the same absolute paths, up to 100 MiB packed, and runs docker in the same working directory there, so relative and absolute paths resolve as they do here. Those files are the build context of build and bake without what .dockerignore leaves out, the files of a build's -f, --build-context, and --secret, the bind mount sources and env files of run and create, and the file that cp, load -i, or import reads.",
2020
- "compose copies its Compose files and env files and, for commands that build or start containers, each build context and each bind-mounted file or directory. ps, logs, down, and other commands that only read the project copy only the Compose files and env files. Variables in Compose files come only from .env and --env-file, and ~ in a Compose file names the home folder of the sandbox.",
2019
+ "Before docker runs, the command copies the local files it reads into the sandbox at the same absolute paths, up to 100 MiB packed, and runs docker in the same working directory there, so relative and absolute paths resolve as they do here. Those files are the build context of build and bake without what .dockerignore leaves out, the files of a build's -f, --build-context, and --secret, the bind mount sources and env files of run and create, the env files of exec, the files that BUILDX_BAKE_FILE and EXPERIMENTAL_BUILDKIT_SOURCE_POLICY name, and the file that cp, load -i, or import reads.",
2020
+ "The variables docker reads come from this computer's environment: a name given to -e or --env with no value on run, create, or exec, a name alone on a line of their --env-file, a name given to build --build-arg with no value, the variable an env --secret reads, and docker's own CLI, Build, and Compose variables, such as DOCKER_DEFAULT_PLATFORM. A name unset here stays unset in the container. The command sends the sandbox only those names and values, and never a variable that picks a daemon, context, builder, or proxy, or names a local config, credential, or certificate path, such as DOCKER_HOST, DOCKER_CONTEXT, DOCKER_CONFIG, or HTTP_PROXY, even one the command names, since the sandbox runs its own Docker daemon.",
2021
+ "compose copies its Compose files and env files and, for commands that build or start containers, each build context and each bind-mounted file or directory. ps, logs, down, and other commands that only read the project copy only the Compose files and env files. Variables in Compose files come from this shell first, then from .env, --env-file, or COMPOSE_ENV_FILES, as with docker compose, and the command sends the sandbox only the shell variables the Compose files and env files name. ~ in a Compose file names the home folder of the sandbox.",
2021
2022
  "Only paths under your home folder or the working directory are copied, a symlink arrives as the link itself, and a path through a symlinked folder fails. What containers wrote stays in the sandbox and never comes back here, and a file deleted here since the last copy is deleted there.",
2022
2023
  "When stdin is not a terminal and docker reads it, as with -i on run or exec without -d, start -i, login --password-stdin, load, import -, build -, or cp -, the command streams stdin to docker as it reads it.",
2023
2024
  "When stdout is not a terminal and docker writes an archive there, as with save or export without -o, cp to -, or build -o -, the archive arrives byte for byte. save and export without -o refuse a terminal, as docker does.",
@@ -3233,6 +3234,10 @@ const billing = {
3233
3234
  name: "billing.plan",
3234
3235
  type: "\"free\" | \"pro\" | \"enterprise\""
3235
3236
  },
3237
+ {
3238
+ name: "billing.plan_billers",
3239
+ type: "array"
3240
+ },
3236
3241
  {
3237
3242
  name: "billing.credit_balance_micro_usd",
3238
3243
  type: "number"
@@ -866,9 +866,13 @@ const Plan = Literals([
866
866
  "pro",
867
867
  ENTERPRISE_PLAN
868
868
  ]).annotate({
869
- description: "The organization plan: `pro` or `enterprise` while that subscription is active, trialing, or past due, otherwise `free`. `enterprise` is Pro for an organization that connects a GitHub account a GitHub Enterprise owns.",
869
+ description: "The organization plan: the higher of the plan of its Stripe subscription while that subscription is active, trialing, or past due, and the plan of a GitHub Marketplace purchase by a GitHub account it connected to Sandcovery CI, otherwise `free`. `enterprise` is Pro for an organization that connects a GitHub account a GitHub Enterprise owns.",
870
870
  identifier: "Plan"
871
871
  });
872
+ const PlanBiller = Literals(["github_marketplace", "stripe"]).annotate({
873
+ description: "Who bills a paid plan: `stripe` for a Stripe subscription, and `github_marketplace` for a GitHub Marketplace purchase, which an owner of the buying GitHub organization changes or cancels in its settings under Billing and licensing.",
874
+ identifier: "PlanBiller"
875
+ });
872
876
  const ProInterval = Literals([
873
877
  "day",
874
878
  "month",
@@ -903,6 +907,7 @@ const Billing = Struct({
903
907
  enterprise_price: EnterprisePrice,
904
908
  github_enterprise: Boolean.annotate({ description: "Whether a GitHub Enterprise owns a GitHub account this organization connected to Sandcovery CI, so that its jobs run only on the Enterprise plan." }),
905
909
  plan: Plan,
910
+ plan_billers: ArraySchema(PlanBiller).annotate({ description: "Who bills each paid plan the organization holds, each biller once: `stripe` while its Stripe subscription grants `plan` or a lower paid plan, and `github_marketplace` while a GitHub Marketplace purchase does. Empty on `free`." }),
906
911
  pro_price: NullOr(ProPrice).annotate({ description: "The Pro price, or null while Pro is not on sale." })
907
912
  }).annotate({ identifier: "Billing" });
908
913
  const CreditTerms = Struct({
@@ -1,6 +1,6 @@
1
1
  import { Br as isString, E as decodeUnknownSync, Ir as hasProperty, Jn as isSuccess, O as fromJsonString, V as optional, Yn as try_, _ as String$1, c as Json, g as Record, n as Boolean, or as getOrUndefined, qn as isFailure, v as Struct, w as decodeUnknownOption } from "./Schema-CoX0a2_o.mjs";
2
- import { $ as exitCodeOf, A as isOptionValue, B as plainPrefix, C as enabledVariable, D as closest, E as productVariable, F as rerunArgv, G as remoteLine, H as theme, J as isDigit, K as remoteText, L as clearLine, M as parseFailure, N as parseLeaf, O as flagOf, P as readOptionToken, Q as CliFailure, R as ellipsis, S as writePrivateFile, T as modeOf, U as escapeUnprintable, V as spinnerFrame, W as remoteCell, X as isUpper, Z as isWordCharacter, b as configDirectory, d as BIN, et as statusOf$1, it as IDLE_WATCHER_ENV, j as lastValue, k as isOptionToken, l as setupDropIns, nt as Canceled, ot as watchIdle, p as CLI, q as consistsOf, r as forwardPorts, st as noop, t as FORWARDER_ENV, tt as usageFailure, w as guidanceOn, y as version, z as glyph } from "./port-forwarder-Du1VlKxg.mjs";
3
- import { m as SANDCOVERY_ORIGIN } from "./src-lrpT0LG_.mjs";
2
+ import { $ as exitCodeOf, A as isOptionValue, B as plainPrefix, C as enabledVariable, D as closest, E as productVariable, F as rerunArgv, G as remoteLine, H as theme, J as isDigit, K as remoteText, L as clearLine, M as parseFailure, N as parseLeaf, O as flagOf, P as readOptionToken, Q as CliFailure, R as ellipsis, S as writePrivateFile, T as modeOf, U as escapeUnprintable, V as spinnerFrame, W as remoteCell, X as isUpper, Z as isWordCharacter, b as configDirectory, d as BIN, et as statusOf$1, it as IDLE_WATCHER_ENV, j as lastValue, k as isOptionToken, l as setupDropIns, nt as Canceled, ot as watchIdle, p as CLI, q as consistsOf, r as forwardPorts, st as noop, t as FORWARDER_ENV, tt as usageFailure, w as guidanceOn, y as version, z as glyph } from "./port-forwarder-DxnuUTsW.mjs";
3
+ import { m as SANDCOVERY_ORIGIN } from "./src-BqfeIyqj.mjs";
4
4
  import { n as sendTelemetry$1, t as loopbackOrigin } from "./telemetry-DBPKT8Ap.mjs";
5
5
  import "./posthog-project-CdWw_ofg.mjs";
6
6
  import http from "node:http";
@@ -1340,7 +1340,7 @@ const runCommand = async ({ invocation, session }) => {
1340
1340
  try {
1341
1341
  const local = LOCAL_COMMANDS.get(key);
1342
1342
  if (local !== void 0) return await local(context);
1343
- const { HANDLERS } = await import("./handlers-U3pqRNro.mjs");
1343
+ const { HANDLERS } = await import("./handlers-B6NdmgQM.mjs");
1344
1344
  const handler = HANDLERS.get(key);
1345
1345
  if (handler === void 0) throw internalFailure(invocation.path);
1346
1346
  return await handler(context);
@@ -44,6 +44,7 @@ interface Billing {
44
44
  readonly enterprise_price: ProPrice | null;
45
45
  readonly github_enterprise: boolean;
46
46
  readonly plan: Plan;
47
+ readonly plan_billers: readonly PlanBiller[];
47
48
  readonly pro_price: ProPrice | null;
48
49
  }
49
50
  interface BrandImage {
@@ -367,6 +368,7 @@ interface Offer {
367
368
  readonly x_post_counted: boolean;
368
369
  }
369
370
  type Plan = "free" | "pro" | "enterprise";
371
+ type PlanBiller = "github_marketplace" | "stripe";
370
372
  interface PortPreview {
371
373
  readonly expires_at: string | null;
372
374
  readonly headers: Readonly<Record<string, string>>;
@@ -788,4 +790,4 @@ interface XPostRequest {
788
790
  readonly url: string;
789
791
  }
790
792
  type ApiError = ConcurrencyLimitReachedError | ConflictError | ForbiddenError | InvalidRequestError | NoProviderAvailableError | NotFoundError | ProviderError | RateLimitedError | SpendLimitReachedError | UnauthorizedError | UnsupportedError;
791
- export { FileList as $, SandboxList as $t, CreateFailureReason as A, XPostRequest as An, ProcessTerminal as At, DetachedExec as B, ProviderPreferences as Bt, CiJob as C, UsageTotal as Cn, Pricing as Ct, ConcurrencyLimitReachedError as D, XAccount as Dn, Process as Dt, CiJobStatus as E, VendorIncidentRead as En, ProblemReportRequest as Et, CredentialField as F, ProviderCatalogEntry as Ft, Estimate as G, REGIONS as Gt, EGRESS_MODES as H, ProviderSort as Ht, CredentialFields as I, ProviderCredential as It, ExecEvent as J, SLUGS as Jt, EstimateList as K, RateLimitedError as Kt, CreditCheckout as L, ProviderCredentialList as Lt, CreateSandboxRequest as M, ProviderBoard as Mt, CreateUsageShareRequest as N, ProviderBoardEntry as Nt, ConflictError as O, XAccountLink as On, ProcessRequest as Ot, CreatedKey as P, ProviderCatalog as Pt, FileEntryType as Q, SandboxEndReason as Qt, CreditPurchaseRequest as R, ProviderError as Rt, CiInstallationList as S, UsageShareList as Sn, PortPreview as St, CiJobList as T, VendorIncident as Tn, ProPrice as Tt, EgressMode as U, ProviderStatus as Ut, DetachedExecRequest as V, ProviderSecurity as Vt, EgressPolicy as W, Provider_1 as Wt, ExecResult as X, Sandbox as Xt, ExecRequest as Y, STANDARD_SIZES as Yt, FileEntry as Z, SandboxCost as Zt, CatalogLimit as _, Usage as _n, NotFoundError as _t, ApiError as a, Slug as an, IncidentImpact as at, CatalogText as b, UsageShare as bn, PROVIDER_1S as bt, AutoTopUpRequest as c, SpendLimitPeriod as cn, KeyKind as ct, BrandImage as d, Stats as dn, LiveSandboxStatus as dt, SandboxStatus as en, ForbiddenError as et, CI_JOB_CONCLUSIONS as f, StatsDay as fn, LiveSandboxes as ft, CatalogGpus as g, UpdateKeyRequest as gn, NoProviderAvailableError as gt, CatalogFlag as h, UnsupportedError as hn, MonthlyCostList as ht, ActivityList as i, SharedUsageFigure as in, Health as it, CreateKeyRequest as j, Provider as jt, CreateAttempt as k, XAccountStatus as kn, ProcessStatus as kt, Badge as l, SpendLimitReachedError as ln, KeyKind_1 as lt, CatalogBrandTerms as m, UnauthorizedError as mn, MonthlyCost as mt, ActivityAction as n, SecurityText as nn, Gpu as nt, AutoTopUp as o, Snapshot as on, InvalidRequestError as ot, CatalogBenchmarkTerms as p, ThemedBrandImage as pn, LiveUsage as pt, EstimateRequest as q, Region as qt, ActivityEvent as r, SharedUsage as rn, GpuType as rt, AutoTopUpChange as s, SpendLimit as sn, Key as st, ACTIVITY_ACTIONS as t, SecurityList as tn, GPU_TYPES as tt, Billing as u, StandardSize as un, KeyList as ut, CatalogList as v, UsageDay as vn, Offer as vt, CiJobConclusion as w, UsageTotals as wn, ProInterval as wt, CiInstallation as x, UsageShareFigure as xn, Plan as xt, CatalogMeasurement as y, UsagePeriod as yn, PROVIDERS as yt, CreditTerms as z, ProviderFeatures as zt };
793
+ export { FileList as $, SandboxEndReason as $t, CreateFailureReason as A, XAccountStatus as An, ProcessStatus as At, DetachedExec as B, ProviderFeatures as Bt, CiJob as C, UsageShareList as Cn, PortPreview as Ct, ConcurrencyLimitReachedError as D, VendorIncidentRead as Dn, ProblemReportRequest as Dt, CiJobStatus as E, VendorIncident as En, ProPrice as Et, CredentialField as F, ProviderCatalog as Ft, Estimate as G, Provider_1 as Gt, EGRESS_MODES as H, ProviderSecurity as Ht, CredentialFields as I, ProviderCatalogEntry as It, ExecEvent as J, Region as Jt, EstimateList as K, REGIONS as Kt, CreditCheckout as L, ProviderCredential as Lt, CreateSandboxRequest as M, Provider as Mt, CreateUsageShareRequest as N, ProviderBoard as Nt, ConflictError as O, XAccount as On, Process as Ot, CreatedKey as P, ProviderBoardEntry as Pt, FileEntryType as Q, SandboxCost as Qt, CreditPurchaseRequest as R, ProviderCredentialList as Rt, CiInstallationList as S, UsageShareFigure as Sn, PlanBiller as St, CiJobList as T, UsageTotals as Tn, ProInterval as Tt, EgressMode as U, ProviderSort as Ut, DetachedExecRequest as V, ProviderPreferences as Vt, EgressPolicy as W, ProviderStatus as Wt, ExecResult as X, STANDARD_SIZES as Xt, ExecRequest as Y, SLUGS as Yt, FileEntry as Z, Sandbox as Zt, CatalogLimit as _, UpdateKeyRequest as _n, NotFoundError as _t, ApiError as a, SharedUsageFigure as an, IncidentImpact as at, CatalogText as b, UsagePeriod as bn, PROVIDER_1S as bt, AutoTopUpRequest as c, SpendLimit as cn, KeyKind as ct, BrandImage as d, StandardSize as dn, LiveSandboxStatus as dt, SandboxList as en, ForbiddenError as et, CI_JOB_CONCLUSIONS as f, Stats as fn, LiveSandboxes as ft, CatalogGpus as g, UnsupportedError as gn, NoProviderAvailableError as gt, CatalogFlag as h, UnauthorizedError as hn, MonthlyCostList as ht, ActivityList as i, SharedUsage as in, Health as it, CreateKeyRequest as j, XPostRequest as jn, ProcessTerminal as jt, CreateAttempt as k, XAccountLink as kn, ProcessRequest as kt, Badge as l, SpendLimitPeriod as ln, KeyKind_1 as lt, CatalogBrandTerms as m, ThemedBrandImage as mn, MonthlyCost as mt, ActivityAction as n, SecurityList as nn, Gpu as nt, AutoTopUp as o, Slug as on, InvalidRequestError as ot, CatalogBenchmarkTerms as p, StatsDay as pn, LiveUsage as pt, EstimateRequest as q, RateLimitedError as qt, ActivityEvent as r, SecurityText as rn, GpuType as rt, AutoTopUpChange as s, Snapshot as sn, Key as st, ACTIVITY_ACTIONS as t, SandboxStatus as tn, GPU_TYPES as tt, Billing as u, SpendLimitReachedError as un, KeyList as ut, CatalogList as v, Usage as vn, Offer as vt, CiJobConclusion as w, UsageTotal as wn, Pricing as wt, CiInstallation as x, UsageShare as xn, Plan as xt, CatalogMeasurement as y, UsageDay as yn, PROVIDERS as yt, CreditTerms as z, ProviderError as zt };
package/dist/types.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- import { $ as FileList, $t as SandboxList, A as CreateFailureReason, An as XPostRequest, At as ProcessTerminal, B as DetachedExec, Bt as ProviderPreferences, C as CiJob, Cn as UsageTotal, Ct as Pricing, D as ConcurrencyLimitReachedError, Dn as XAccount, Dt as Process, E as CiJobStatus, En as VendorIncidentRead, Et as ProblemReportRequest, F as CredentialField, Ft as ProviderCatalogEntry, G as Estimate, Gt as REGIONS, H as EGRESS_MODES, Ht as ProviderSort, I as CredentialFields, It as ProviderCredential, J as ExecEvent, Jt as SLUGS, K as EstimateList, Kt as RateLimitedError, L as CreditCheckout, Lt as ProviderCredentialList, M as CreateSandboxRequest, Mt as ProviderBoard, N as CreateUsageShareRequest, Nt as ProviderBoardEntry, O as ConflictError, On as XAccountLink, Ot as ProcessRequest, P as CreatedKey, Pt as ProviderCatalog, Q as FileEntryType, Qt as SandboxEndReason, R as CreditPurchaseRequest, Rt as ProviderError, S as CiInstallationList, Sn as UsageShareList, St as PortPreview, T as CiJobList, Tn as VendorIncident, Tt as ProPrice, U as EgressMode, Ut as ProviderStatus, V as DetachedExecRequest, Vt as ProviderSecurity, W as EgressPolicy, Wt as Provider_1, X as ExecResult, Xt as Sandbox, Y as ExecRequest, Yt as STANDARD_SIZES, Z as FileEntry, Zt as SandboxCost, _ as CatalogLimit, _n as Usage, _t as NotFoundError, a as ApiError, an as Slug, at as IncidentImpact, b as CatalogText, bn as UsageShare, bt as PROVIDER_1S, c as AutoTopUpRequest, cn as SpendLimitPeriod, ct as KeyKind, d as BrandImage, dn as Stats, dt as LiveSandboxStatus, en as SandboxStatus, et as ForbiddenError, f as CI_JOB_CONCLUSIONS, fn as StatsDay, ft as LiveSandboxes, g as CatalogGpus, gn as UpdateKeyRequest, gt as NoProviderAvailableError, h as CatalogFlag, hn as UnsupportedError, ht as MonthlyCostList, i as ActivityList, in as SharedUsageFigure, it as Health, j as CreateKeyRequest, jt as Provider, k as CreateAttempt, kn as XAccountStatus, kt as ProcessStatus, l as Badge, ln as SpendLimitReachedError, lt as KeyKind_1, m as CatalogBrandTerms, mn as UnauthorizedError, mt as MonthlyCost, n as ActivityAction, nn as SecurityText, nt as Gpu, o as AutoTopUp, on as Snapshot, ot as InvalidRequestError, p as CatalogBenchmarkTerms, pn as ThemedBrandImage, pt as LiveUsage, q as EstimateRequest, qt as Region, r as ActivityEvent, rn as SharedUsage, rt as GpuType, s as AutoTopUpChange, sn as SpendLimit, st as Key, t as ACTIVITY_ACTIONS, tn as SecurityList, tt as GPU_TYPES, u as Billing, un as StandardSize, ut as KeyList, v as CatalogList, vn as UsageDay, vt as Offer, w as CiJobConclusion, wn as UsageTotals, wt as ProInterval, x as CiInstallation, xn as UsageShareFigure, xt as Plan, y as CatalogMeasurement, yn as UsagePeriod, yt as PROVIDERS, z as CreditTerms, zt as ProviderFeatures } from "./types-C7lGEXT5.mjs";
2
- export { ACTIVITY_ACTIONS, ActivityAction, ActivityEvent, ActivityList, ApiError, AutoTopUp, AutoTopUpChange, AutoTopUpRequest, Badge, Billing, BrandImage, CI_JOB_CONCLUSIONS, CatalogBenchmarkTerms, CatalogBrandTerms, CatalogFlag, CatalogGpus, CatalogLimit, CatalogList, CatalogMeasurement, CatalogText, CiInstallation, CiInstallationList, CiJob, CiJobConclusion, CiJobList, CiJobStatus, ConcurrencyLimitReachedError, ConflictError, CreateAttempt, CreateFailureReason, CreateKeyRequest, CreateSandboxRequest, CreateUsageShareRequest, CreatedKey, CredentialField, CredentialFields, CreditCheckout, CreditPurchaseRequest, CreditTerms, DetachedExec, DetachedExecRequest, EGRESS_MODES, EgressMode, EgressPolicy, Estimate, EstimateList, EstimateRequest, ExecEvent, ExecRequest, ExecResult, FileEntry, FileEntryType, FileList, ForbiddenError, GPU_TYPES, Gpu, GpuType, Health, IncidentImpact, InvalidRequestError, Key, KeyKind, KeyKind_1, KeyList, LiveSandboxStatus, LiveSandboxes, LiveUsage, MonthlyCost, MonthlyCostList, NoProviderAvailableError, NotFoundError, Offer, PROVIDERS, PROVIDER_1S, Plan, PortPreview, Pricing, ProInterval, ProPrice, ProblemReportRequest, Process, ProcessRequest, ProcessStatus, ProcessTerminal, Provider, ProviderBoard, ProviderBoardEntry, ProviderCatalog, ProviderCatalogEntry, ProviderCredential, ProviderCredentialList, ProviderError, ProviderFeatures, ProviderPreferences, ProviderSecurity, ProviderSort, ProviderStatus, Provider_1, REGIONS, RateLimitedError, Region, SLUGS, STANDARD_SIZES, Sandbox, SandboxCost, SandboxEndReason, SandboxList, SandboxStatus, SecurityList, SecurityText, SharedUsage, SharedUsageFigure, Slug, Snapshot, SpendLimit, SpendLimitPeriod, SpendLimitReachedError, StandardSize, Stats, StatsDay, ThemedBrandImage, UnauthorizedError, UnsupportedError, UpdateKeyRequest, Usage, UsageDay, UsagePeriod, UsageShare, UsageShareFigure, UsageShareList, UsageTotal, UsageTotals, VendorIncident, VendorIncidentRead, XAccount, XAccountLink, XAccountStatus, XPostRequest };
1
+ import { $ as FileList, $t as SandboxEndReason, A as CreateFailureReason, An as XAccountStatus, At as ProcessStatus, B as DetachedExec, Bt as ProviderFeatures, C as CiJob, Cn as UsageShareList, Ct as PortPreview, D as ConcurrencyLimitReachedError, Dn as VendorIncidentRead, Dt as ProblemReportRequest, E as CiJobStatus, En as VendorIncident, Et as ProPrice, F as CredentialField, Ft as ProviderCatalog, G as Estimate, Gt as Provider_1, H as EGRESS_MODES, Ht as ProviderSecurity, I as CredentialFields, It as ProviderCatalogEntry, J as ExecEvent, Jt as Region, K as EstimateList, Kt as REGIONS, L as CreditCheckout, Lt as ProviderCredential, M as CreateSandboxRequest, Mt as Provider, N as CreateUsageShareRequest, Nt as ProviderBoard, O as ConflictError, On as XAccount, Ot as Process, P as CreatedKey, Pt as ProviderBoardEntry, Q as FileEntryType, Qt as SandboxCost, R as CreditPurchaseRequest, Rt as ProviderCredentialList, S as CiInstallationList, Sn as UsageShareFigure, St as PlanBiller, T as CiJobList, Tn as UsageTotals, Tt as ProInterval, U as EgressMode, Ut as ProviderSort, V as DetachedExecRequest, Vt as ProviderPreferences, W as EgressPolicy, Wt as ProviderStatus, X as ExecResult, Xt as STANDARD_SIZES, Y as ExecRequest, Yt as SLUGS, Z as FileEntry, Zt as Sandbox, _ as CatalogLimit, _n as UpdateKeyRequest, _t as NotFoundError, a as ApiError, an as SharedUsageFigure, at as IncidentImpact, b as CatalogText, bn as UsagePeriod, bt as PROVIDER_1S, c as AutoTopUpRequest, cn as SpendLimit, ct as KeyKind, d as BrandImage, dn as StandardSize, dt as LiveSandboxStatus, en as SandboxList, et as ForbiddenError, f as CI_JOB_CONCLUSIONS, fn as Stats, ft as LiveSandboxes, g as CatalogGpus, gn as UnsupportedError, gt as NoProviderAvailableError, h as CatalogFlag, hn as UnauthorizedError, ht as MonthlyCostList, i as ActivityList, in as SharedUsage, it as Health, j as CreateKeyRequest, jn as XPostRequest, jt as ProcessTerminal, k as CreateAttempt, kn as XAccountLink, kt as ProcessRequest, l as Badge, ln as SpendLimitPeriod, lt as KeyKind_1, m as CatalogBrandTerms, mn as ThemedBrandImage, mt as MonthlyCost, n as ActivityAction, nn as SecurityList, nt as Gpu, o as AutoTopUp, on as Slug, ot as InvalidRequestError, p as CatalogBenchmarkTerms, pn as StatsDay, pt as LiveUsage, q as EstimateRequest, qt as RateLimitedError, r as ActivityEvent, rn as SecurityText, rt as GpuType, s as AutoTopUpChange, sn as Snapshot, st as Key, t as ACTIVITY_ACTIONS, tn as SandboxStatus, tt as GPU_TYPES, u as Billing, un as SpendLimitReachedError, ut as KeyList, v as CatalogList, vn as Usage, vt as Offer, w as CiJobConclusion, wn as UsageTotal, wt as Pricing, x as CiInstallation, xn as UsageShare, xt as Plan, y as CatalogMeasurement, yn as UsageDay, yt as PROVIDERS, z as CreditTerms, zt as ProviderError } from "./types-C4amb2QE.mjs";
2
+ export { ACTIVITY_ACTIONS, ActivityAction, ActivityEvent, ActivityList, ApiError, AutoTopUp, AutoTopUpChange, AutoTopUpRequest, Badge, Billing, BrandImage, CI_JOB_CONCLUSIONS, CatalogBenchmarkTerms, CatalogBrandTerms, CatalogFlag, CatalogGpus, CatalogLimit, CatalogList, CatalogMeasurement, CatalogText, CiInstallation, CiInstallationList, CiJob, CiJobConclusion, CiJobList, CiJobStatus, ConcurrencyLimitReachedError, ConflictError, CreateAttempt, CreateFailureReason, CreateKeyRequest, CreateSandboxRequest, CreateUsageShareRequest, CreatedKey, CredentialField, CredentialFields, CreditCheckout, CreditPurchaseRequest, CreditTerms, DetachedExec, DetachedExecRequest, EGRESS_MODES, EgressMode, EgressPolicy, Estimate, EstimateList, EstimateRequest, ExecEvent, ExecRequest, ExecResult, FileEntry, FileEntryType, FileList, ForbiddenError, GPU_TYPES, Gpu, GpuType, Health, IncidentImpact, InvalidRequestError, Key, KeyKind, KeyKind_1, KeyList, LiveSandboxStatus, LiveSandboxes, LiveUsage, MonthlyCost, MonthlyCostList, NoProviderAvailableError, NotFoundError, Offer, PROVIDERS, PROVIDER_1S, Plan, PlanBiller, PortPreview, Pricing, ProInterval, ProPrice, ProblemReportRequest, Process, ProcessRequest, ProcessStatus, ProcessTerminal, Provider, ProviderBoard, ProviderBoardEntry, ProviderCatalog, ProviderCatalogEntry, ProviderCredential, ProviderCredentialList, ProviderError, ProviderFeatures, ProviderPreferences, ProviderSecurity, ProviderSort, ProviderStatus, Provider_1, REGIONS, RateLimitedError, Region, SLUGS, STANDARD_SIZES, Sandbox, SandboxCost, SandboxEndReason, SandboxList, SandboxStatus, SecurityList, SecurityText, SharedUsage, SharedUsageFigure, Slug, Snapshot, SpendLimit, SpendLimitPeriod, SpendLimitReachedError, StandardSize, Stats, StatsDay, ThemedBrandImage, UnauthorizedError, UnsupportedError, UpdateKeyRequest, Usage, UsageDay, UsagePeriod, UsageShare, UsageShareFigure, UsageShareList, UsageTotal, UsageTotals, VendorIncident, VendorIncidentRead, XAccount, XAccountLink, XAccountStatus, XPostRequest };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sandcovery",
3
- "version": "0.6.0",
3
+ "version": "0.6.1",
4
4
  "description": "One API for every sandbox provider. Better prices, better uptime.",
5
5
  "keywords": [
6
6
  "daytona",