@geekmidas/cli 10.0.0-alpha.103 → 10.0.0-alpha.105
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/{EndpointGenerator-By5_tYE9.cjs → EndpointGenerator-BwbYTMtB.cjs} +2 -2
- package/dist/{EndpointGenerator-By5_tYE9.cjs.map → EndpointGenerator-BwbYTMtB.cjs.map} +1 -1
- package/dist/{EndpointGenerator-Br97xgs_.mjs → EndpointGenerator-CvLX8bpx.mjs} +2 -2
- package/dist/{EndpointGenerator-Br97xgs_.mjs.map → EndpointGenerator-CvLX8bpx.mjs.map} +1 -1
- package/dist/{GoDaddyProvider-JITjarl9.cjs → GoDaddyProvider-Cr9Uvqyz.cjs} +2 -2
- package/dist/{GoDaddyProvider-JITjarl9.cjs.map → GoDaddyProvider-Cr9Uvqyz.cjs.map} +1 -1
- package/dist/{GoDaddyProvider-8gNDqaml.mjs → GoDaddyProvider-DjtX8TUM.mjs} +2 -2
- package/dist/{GoDaddyProvider-8gNDqaml.mjs.map → GoDaddyProvider-DjtX8TUM.mjs.map} +1 -1
- package/dist/{LegacyStateStore-D-mcT2Z7.cjs → LegacyStateStore-CnxFZGeQ.cjs} +3 -3
- package/dist/{LegacyStateStore-D-mcT2Z7.cjs.map → LegacyStateStore-CnxFZGeQ.cjs.map} +1 -1
- package/dist/{LegacyStateStore-C0WnyYy_.mjs → LegacyStateStore-D-0XrizH.mjs} +3 -3
- package/dist/{LegacyStateStore-C0WnyYy_.mjs.map → LegacyStateStore-D-0XrizH.mjs.map} +1 -1
- package/dist/{LocalStateStore-CUFfdu-v.cjs → LocalStateStore-DGR_KzjD.cjs} +2 -2
- package/dist/{LocalStateStore-CUFfdu-v.cjs.map → LocalStateStore-DGR_KzjD.cjs.map} +1 -1
- package/dist/{LocalStateStore-C_8QWB2r.mjs → LocalStateStore-dVcU5RNe.mjs} +2 -2
- package/dist/{LocalStateStore-C_8QWB2r.mjs.map → LocalStateStore-dVcU5RNe.mjs.map} +1 -1
- package/dist/{OpenApiTsGenerator-BgSX_Z-e.cjs → OpenApiTsGenerator-BD6ZOQ51.cjs} +2 -2
- package/dist/{OpenApiTsGenerator-BgSX_Z-e.cjs.map → OpenApiTsGenerator-BD6ZOQ51.cjs.map} +1 -1
- package/dist/{OpenApiTsGenerator-C8aTX--y.mjs → OpenApiTsGenerator-DXXFXSbO.mjs} +2 -2
- package/dist/{OpenApiTsGenerator-C8aTX--y.mjs.map → OpenApiTsGenerator-DXXFXSbO.mjs.map} +1 -1
- package/dist/{S3StateStore-DIJ6CCv_.cjs → S3StateStore-D8z0z8P2.cjs} +2 -2
- package/dist/{S3StateStore-DIJ6CCv_.cjs.map → S3StateStore-D8z0z8P2.cjs.map} +1 -1
- package/dist/{S3StateStore-B0Vy19db.mjs → S3StateStore-DIyP76Kb.mjs} +2 -2
- package/dist/{S3StateStore-B0Vy19db.mjs.map → S3StateStore-DIyP76Kb.mjs.map} +1 -1
- package/dist/{SSMStateStore-DgBlEqYO.mjs → SSMStateStore-B7J_fv0d.mjs} +2 -2
- package/dist/{SSMStateStore-DgBlEqYO.mjs.map → SSMStateStore-B7J_fv0d.mjs.map} +1 -1
- package/dist/{SSMStateStore-D577um0e.cjs → SSMStateStore-CIOsbEcQ.cjs} +2 -2
- package/dist/{SSMStateStore-D577um0e.cjs.map → SSMStateStore-CIOsbEcQ.cjs.map} +1 -1
- package/dist/{SubscriberGenerator-DmPM_3c5.cjs → SubscriberGenerator-CeH7wbYt.cjs} +3 -3
- package/dist/{SubscriberGenerator-DmPM_3c5.cjs.map → SubscriberGenerator-CeH7wbYt.cjs.map} +1 -1
- package/dist/{SubscriberGenerator-YK-7ewmi.mjs → SubscriberGenerator-DHnIYwUU.mjs} +3 -3
- package/dist/{SubscriberGenerator-YK-7ewmi.mjs.map → SubscriberGenerator-DHnIYwUU.mjs.map} +1 -1
- package/dist/{add-BJJKhUnO.mjs → add-CC69Yf5t.mjs} +8 -9
- package/dist/add-CC69Yf5t.mjs.map +1 -0
- package/dist/{add-D97HfZ7z.cjs → add-DWj9Kccz.cjs} +8 -9
- package/dist/add-DWj9Kccz.cjs.map +1 -0
- package/dist/{bundler-CzbrMpDf.mjs → bundler-BpYpp1Hf.mjs} +5 -5
- package/dist/{bundler-CzbrMpDf.mjs.map → bundler-BpYpp1Hf.mjs.map} +1 -1
- package/dist/{bundler-CtEQAnym.cjs → bundler-TZ72P7LF.cjs} +5 -5
- package/dist/{bundler-CtEQAnym.cjs.map → bundler-TZ72P7LF.cjs.map} +1 -1
- package/dist/{cli-D_zrFs9-.mjs → cli-BZ_9cc0O.mjs} +3 -3
- package/dist/{cli-D_zrFs9-.mjs.map → cli-BZ_9cc0O.mjs.map} +1 -1
- package/dist/{cli-CIv8PA-v.cjs → cli-iqNUZ9Va.cjs} +3 -3
- package/dist/{cli-CIv8PA-v.cjs.map → cli-iqNUZ9Va.cjs.map} +1 -1
- package/dist/{compose-BviikvXq.cjs → compose-5b4lzIyr.cjs} +14 -11
- package/dist/compose-5b4lzIyr.cjs.map +1 -0
- package/dist/{compose-DtPhKs0u.mjs → compose-BXUDOrte.mjs} +14 -11
- package/dist/{compose-DtPhKs0u.mjs.map → compose-BXUDOrte.mjs.map} +1 -1
- package/dist/config.cjs +1 -1
- package/dist/config.mjs +1 -1
- package/dist/{credentialSchemas-DvitraL-.mjs → credentialSchemas-Cf5Pf8VE.mjs} +2 -2
- package/dist/{credentialSchemas-DvitraL-.mjs.map → credentialSchemas-Cf5Pf8VE.mjs.map} +1 -1
- package/dist/{credentialSchemas-DDda4Mmm.cjs → credentialSchemas-D_VUCDUh.cjs} +2 -2
- package/dist/{credentialSchemas-DDda4Mmm.cjs.map → credentialSchemas-D_VUCDUh.cjs.map} +1 -1
- package/dist/deploy/public.cjs +7 -7
- package/dist/deploy/public.mjs +7 -7
- package/dist/{deploy-DyPt41Oq.mjs → deploy-BXx5PHR8.mjs} +8 -8
- package/dist/{deploy-DyPt41Oq.mjs.map → deploy-BXx5PHR8.mjs.map} +1 -1
- package/dist/{deploy-cv0i1yFo.cjs → deploy-rdTC6BqI.cjs} +8 -8
- package/dist/{deploy-cv0i1yFo.cjs.map → deploy-rdTC6BqI.cjs.map} +1 -1
- package/dist/{discover-BfhVW_kT.cjs → discover-Bsr7HjqJ.cjs} +18 -2
- package/dist/{discover-BfhVW_kT.cjs.map → discover-Bsr7HjqJ.cjs.map} +1 -1
- package/dist/{discover-kziEht4W.mjs → discover-Ca8U75dl.mjs} +13 -3
- package/dist/{discover-kziEht4W.mjs.map → discover-Ca8U75dl.mjs.map} +1 -1
- package/dist/{dns-B-wqZiyQ.mjs → dns-CRungu5C.mjs} +2 -2
- package/dist/{dns-B-wqZiyQ.mjs.map → dns-CRungu5C.mjs.map} +1 -1
- package/dist/{dns-_rxfINeq.cjs → dns-FMg7REGo.cjs} +2 -2
- package/dist/{dns-_rxfINeq.cjs.map → dns-FMg7REGo.cjs.map} +1 -1
- package/dist/{dokploy-BJQ9HjVv.mjs → dokploy-CuluaeVl.mjs} +2 -2
- package/dist/{dokploy-BJQ9HjVv.mjs.map → dokploy-CuluaeVl.mjs.map} +1 -1
- package/dist/{dokploy-DSvw-l5b.cjs → dokploy-U_yXwsT7.cjs} +2 -2
- package/dist/{dokploy-DSvw-l5b.cjs.map → dokploy-U_yXwsT7.cjs.map} +1 -1
- package/dist/{drivers-OXhPkaNB.mjs → drivers-D11JHxrD.mjs} +2 -2
- package/dist/{drivers-OXhPkaNB.mjs.map → drivers-D11JHxrD.mjs.map} +1 -1
- package/dist/{drivers-DEDL8vPE.cjs → drivers-GKaA6ITM.cjs} +2 -2
- package/dist/{drivers-DEDL8vPE.cjs.map → drivers-GKaA6ITM.cjs.map} +1 -1
- package/dist/{encryption-UgYs2YYM.cjs → encryption-D-louLFQ.cjs} +2 -2
- package/dist/{encryption-UgYs2YYM.cjs.map → encryption-D-louLFQ.cjs.map} +1 -1
- package/dist/{encryption-BUAZ3OEJ.mjs → encryption-XqokmrEn.mjs} +2 -2
- package/dist/{encryption-BUAZ3OEJ.mjs.map → encryption-XqokmrEn.mjs.map} +1 -1
- package/dist/{engine-Blx6G12-.cjs → engine-BdpcrYWi.cjs} +6 -5
- package/dist/engine-BdpcrYWi.cjs.map +1 -0
- package/dist/{engine-VnbN4VnX.mjs → engine-DqNljyye.mjs} +6 -5
- package/dist/engine-DqNljyye.mjs.map +1 -0
- package/dist/{github-C-L3qfYZ.cjs → github-CA33zfqv.cjs} +5 -5
- package/dist/{github-C-L3qfYZ.cjs.map → github-CA33zfqv.cjs.map} +1 -1
- package/dist/{github-D2uJ32Af.mjs → github-b_kS4jvw.mjs} +5 -5
- package/dist/{github-D2uJ32Af.mjs.map → github-b_kS4jvw.mjs.map} +1 -1
- package/dist/index.cjs +180 -101
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +181 -102
- package/dist/index.mjs.map +1 -1
- package/dist/{migrate-DdociPvx.cjs → migrate-BVMk0jtV.cjs} +3 -3
- package/dist/{migrate-DdociPvx.cjs.map → migrate-BVMk0jtV.cjs.map} +1 -1
- package/dist/{migrate-BFH52jlU.mjs → migrate-DBp_H1fe.mjs} +3 -3
- package/dist/{migrate-BFH52jlU.mjs.map → migrate-DBp_H1fe.mjs.map} +1 -1
- package/dist/{migrate-Dqjr7rfs.mjs → migrate-DStsGGqC.mjs} +2 -2
- package/dist/{migrate-Dqjr7rfs.mjs.map → migrate-DStsGGqC.mjs.map} +1 -1
- package/dist/{migrate-DxAFe2EV.cjs → migrate-Ln16jIxy.cjs} +2 -2
- package/dist/{migrate-DxAFe2EV.cjs.map → migrate-Ln16jIxy.cjs.map} +1 -1
- package/dist/openapi.cjs +2 -2
- package/dist/openapi.mjs +2 -2
- package/dist/{ready-D38XpZ0L.cjs → ready-BMFjxBYA.cjs} +8 -7
- package/dist/ready-BMFjxBYA.cjs.map +1 -0
- package/dist/{ready-CuSU8Ap0.mjs → ready-CIt5SOtg.mjs} +8 -7
- package/dist/ready-CIt5SOtg.mjs.map +1 -0
- package/dist/reconcile/public.cjs +1 -1
- package/dist/reconcile/public.mjs +1 -1
- package/dist/{resolve-aqhkZfDI.cjs → resolve-CJ91HNQB.cjs} +3 -3
- package/dist/{resolve-aqhkZfDI.cjs.map → resolve-CJ91HNQB.cjs.map} +1 -1
- package/dist/{resolve-BGgwxfCz.mjs → resolve-DCdFajey.mjs} +3 -3
- package/dist/{resolve-BGgwxfCz.mjs.map → resolve-DCdFajey.mjs.map} +1 -1
- package/dist/{rollback-DUbUQeoz.mjs → rollback-CNS-52X9.mjs} +4 -4
- package/dist/{rollback-DUbUQeoz.mjs.map → rollback-CNS-52X9.mjs.map} +1 -1
- package/dist/{rollback-qk3-knJ7.cjs → rollback-UFitatDM.cjs} +4 -4
- package/dist/{rollback-qk3-knJ7.cjs.map → rollback-UFitatDM.cjs.map} +1 -1
- package/dist/sandbox/credentials-worker.cjs +2 -2
- package/dist/sandbox/credentials-worker.mjs +2 -2
- package/dist/sandbox/discover-worker.cjs +1 -1
- package/dist/sandbox/discover-worker.mjs +1 -1
- package/dist/sandbox/migrate-worker.cjs +1 -1
- package/dist/sandbox/migrate-worker.mjs +1 -1
- package/dist/{seeds-Cx8NmuQj.mjs → seeds-BfzwCdYv.mjs} +62 -53
- package/dist/seeds-BfzwCdYv.mjs.map +1 -0
- package/dist/{seeds-a1H3kuqu.cjs → seeds-DkcKQ_F8.cjs} +66 -51
- package/dist/seeds-DkcKQ_F8.cjs.map +1 -0
- package/dist/{sniffer-Bt2H-BZ_.mjs → sniffer-B1neuJz2.mjs} +7 -7
- package/dist/{sniffer-Bt2H-BZ_.mjs.map → sniffer-B1neuJz2.mjs.map} +1 -1
- package/dist/{sniffer-DxYAi7bz.cjs → sniffer-DgfzmvB7.cjs} +7 -7
- package/dist/{sniffer-DxYAi7bz.cjs.map → sniffer-DgfzmvB7.cjs.map} +1 -1
- package/dist/target/public.cjs +1 -1
- package/dist/target/public.mjs +1 -1
- package/dist/{terminal-Bs_lNQhL.mjs → terminal-CvRLxz6g.mjs} +2 -2
- package/dist/{terminal-Bs_lNQhL.mjs.map → terminal-CvRLxz6g.mjs.map} +1 -1
- package/dist/{terminal-CsQz4oT0.cjs → terminal-D_NRPW4W.cjs} +2 -2
- package/dist/{terminal-CsQz4oT0.cjs.map → terminal-D_NRPW4W.cjs.map} +1 -1
- package/dist/vitest.cjs +1 -1
- package/dist/vitest.mjs +1 -1
- package/package.json +15 -15
- package/dist/add-BJJKhUnO.mjs.map +0 -1
- package/dist/add-D97HfZ7z.cjs.map +0 -1
- package/dist/compose-BviikvXq.cjs.map +0 -1
- package/dist/engine-Blx6G12-.cjs.map +0 -1
- package/dist/engine-VnbN4VnX.mjs.map +0 -1
- package/dist/ready-CuSU8Ap0.mjs.map +0 -1
- package/dist/ready-D38XpZ0L.cjs.map +0 -1
- package/dist/seeds-Cx8NmuQj.mjs.map +0 -1
- package/dist/seeds-a1H3kuqu.cjs.map +0 -1
|
@@ -3,12 +3,12 @@ const require_errors = require("./errors-DMC4Umsb.cjs");
|
|
|
3
3
|
const require_run = require("./run-fVZ-rLnc.cjs");
|
|
4
4
|
const require_workspace = require("./workspace-BwqQnool.cjs");
|
|
5
5
|
const require_derive = require("./derive-DAbo49sm.cjs");
|
|
6
|
-
const require_SubscriberGenerator = require("./SubscriberGenerator-
|
|
6
|
+
const require_SubscriberGenerator = require("./SubscriberGenerator-CeH7wbYt.cjs");
|
|
7
7
|
const require_identity = require("./identity-CbLfgQNT.cjs");
|
|
8
|
-
const require_EndpointGenerator = require("./EndpointGenerator-
|
|
9
|
-
const require_discover = require("./discover-
|
|
8
|
+
const require_EndpointGenerator = require("./EndpointGenerator-BwbYTMtB.cjs");
|
|
9
|
+
const require_discover = require("./discover-Bsr7HjqJ.cjs");
|
|
10
10
|
const require_config = require("./config.cjs");
|
|
11
|
-
const require_resolve = require("./resolve-
|
|
11
|
+
const require_resolve = require("./resolve-CJ91HNQB.cjs");
|
|
12
12
|
let node_path = require("node:path");
|
|
13
13
|
let node_fs = require("node:fs");
|
|
14
14
|
let node_fs_promises = require("node:fs/promises");
|
|
@@ -726,10 +726,8 @@ function emulatorQueueUrl(name, port) {
|
|
|
726
726
|
* Which processes use a `Telemetry` node — read off the manifest's edges.
|
|
727
727
|
*
|
|
728
728
|
* A process uses telemetry when its own declaration names the node: a
|
|
729
|
-
* surface's `telemetry`, a worker's.
|
|
730
|
-
*
|
|
731
|
-
* consumers under `gkm dev`, and is handed their edges' keys by `appEnvKeys`,
|
|
732
|
-
* so a worker's edge counts for it too — the same rule, read the same way.
|
|
729
|
+
* surface's `telemetry`, a worker's. A surface's process runs its own
|
|
730
|
+
* endpoints, so a worker's edge never counts for it.
|
|
733
731
|
*
|
|
734
732
|
* A site's edge is recorded and never followed here: a site is handed none of
|
|
735
733
|
* the node's keys (see `PUBLIC.telemetry`).
|
|
@@ -755,14 +753,7 @@ function telemetryOf(manifest, id) {
|
|
|
755
753
|
if (!declaration) return void 0;
|
|
756
754
|
if (declaration.kind === "worker") return nodeOf(manifest, declaration.telemetry);
|
|
757
755
|
if (declaration.kind !== "rest-api") return void 0;
|
|
758
|
-
|
|
759
|
-
if (own) return own;
|
|
760
|
-
if (declaration.endpoints.length > 0) return void 0;
|
|
761
|
-
for (const other of Object.values(manifest)) {
|
|
762
|
-
if (other.kind !== "worker") continue;
|
|
763
|
-
const node = nodeOf(manifest, other.telemetry);
|
|
764
|
-
if (node) return node;
|
|
765
|
-
}
|
|
756
|
+
return nodeOf(manifest, declaration.telemetry);
|
|
766
757
|
}
|
|
767
758
|
/**
|
|
768
759
|
* The `Telemetry` node the app `appName` emits through — its surface's, or
|
|
@@ -1042,6 +1033,10 @@ function planFor(manifest, stage, order, options = {}) {
|
|
|
1042
1033
|
} } : {},
|
|
1043
1034
|
...declaration.kind === "external-api" && !fake ? { url: declaration.url } : {},
|
|
1044
1035
|
...declaration.kind === "credential" && options.credentialFakes?.[id] !== void 0 ? { fakeCredentials: options.credentialFakes[id] } : {},
|
|
1036
|
+
...declaration.kind === "secret" && (declaration.length !== void 0 || declaration.symbols !== void 0) ? { format: {
|
|
1037
|
+
...declaration.length !== void 0 ? { length: declaration.length } : {},
|
|
1038
|
+
...declaration.symbols !== void 0 ? { symbols: declaration.symbols } : {}
|
|
1039
|
+
} } : {},
|
|
1045
1040
|
..."of" in declaration && !detached ? { of: declaration.of } : {},
|
|
1046
1041
|
..."schema" in declaration && declaration.schema ? { schema: declaration.schema } : {},
|
|
1047
1042
|
..."version" in declaration && declaration.version ? { version: declaration.version } : {},
|
|
@@ -1561,10 +1556,36 @@ function localKeyring(project, plan, resource) {
|
|
|
1561
1556
|
* A hash of what identifies it, so it is stable, distinct per project, stage
|
|
1562
1557
|
* and construct, and never written to disk as a literal. Deployed this is the
|
|
1563
1558
|
* one kind whose value does *not* come from here — a secret manager generates
|
|
1564
|
-
* it once and the target reads it back.
|
|
1559
|
+
* it once and the target reads it back. Drawn in the format the deploy draws
|
|
1560
|
+
* it in, so a value that passes a third party's rules here passes them there.
|
|
1565
1561
|
*/
|
|
1566
1562
|
function localSecret(project, plan, resource) {
|
|
1567
|
-
return (0,
|
|
1563
|
+
return (0, _geekmidas_manifest.drawSecret)(hashStream(`${project}:${plan.stage}:${resource.id}`), resource.format);
|
|
1564
|
+
}
|
|
1565
|
+
/**
|
|
1566
|
+
* Integers in `[0, n)` drawn from a hash of `seed`, the same every time —
|
|
1567
|
+
* what a local secret is drawn with instead of `crypto`, so `gkm dev` and
|
|
1568
|
+
* `gkm test` need nothing stored. Rejection-sampled, so no character is
|
|
1569
|
+
* likelier than another.
|
|
1570
|
+
*/
|
|
1571
|
+
function hashStream(seed) {
|
|
1572
|
+
let block = 0;
|
|
1573
|
+
let bytes = Buffer.alloc(0);
|
|
1574
|
+
let offset = 0;
|
|
1575
|
+
const next = () => {
|
|
1576
|
+
if (offset === bytes.length) {
|
|
1577
|
+
bytes = (0, node_crypto.createHash)("sha256").update(`${seed}:${block++}`).digest();
|
|
1578
|
+
offset = 0;
|
|
1579
|
+
}
|
|
1580
|
+
return bytes[offset++];
|
|
1581
|
+
};
|
|
1582
|
+
return (n) => {
|
|
1583
|
+
const limit = 256 - 256 % n;
|
|
1584
|
+
for (;;) {
|
|
1585
|
+
const byte = next();
|
|
1586
|
+
if (byte < limit) return byte % n;
|
|
1587
|
+
}
|
|
1588
|
+
};
|
|
1568
1589
|
}
|
|
1569
1590
|
//#endregion
|
|
1570
1591
|
//#region src/compose/redis.ts
|
|
@@ -1722,8 +1743,8 @@ function redisService(redis) {
|
|
|
1722
1743
|
* master and roles, a bucket's root user. Derived from repo facts alone
|
|
1723
1744
|
* (project, stage, construct id), those passwords were computable by anyone
|
|
1724
1745
|
* who could read the repo.
|
|
1725
|
-
* - **Each `secret` construct's value** — an auth server's signing secret
|
|
1726
|
-
* random, rather than derived.
|
|
1746
|
+
* - **Each `secret` construct's value** — an auth server's signing secret, a
|
|
1747
|
+
* `RandomPassword` — random, rather than derived, in its declared format.
|
|
1727
1748
|
* - **Each `encryption` construct's keyring** — one random key and an index
|
|
1728
1749
|
* key. Later keys are added by `gkm encryption:rotate`, never by a deploy.
|
|
1729
1750
|
*
|
|
@@ -1744,7 +1765,7 @@ function withGeneratedSecrets(secrets, manifest) {
|
|
|
1744
1765
|
if (declaration?.kind !== "secret" && declaration?.kind !== "encryption") continue;
|
|
1745
1766
|
const key = declaration.provides?.[0];
|
|
1746
1767
|
if (!key || custom[key]) continue;
|
|
1747
|
-
custom[key] = declaration.kind === "encryption" ? (0, _geekmidas_constructs_encryption.generateKeyring)() :
|
|
1768
|
+
custom[key] = declaration.kind === "encryption" ? (0, _geekmidas_constructs_encryption.generateKeyring)() : (0, _geekmidas_manifest.drawSecret)(node_crypto.randomInt, declaration);
|
|
1748
1769
|
generated.push(key);
|
|
1749
1770
|
}
|
|
1750
1771
|
const seed = secrets.seed ?? generateSeed();
|
|
@@ -2615,6 +2636,7 @@ function workerUnits(workspace, manifest, background) {
|
|
|
2615
2636
|
}
|
|
2616
2637
|
return units.sort((a, b) => a.name.localeCompare(b.name));
|
|
2617
2638
|
}
|
|
2639
|
+
/** Whether `file` is inside `dir`. */
|
|
2618
2640
|
function isUnder(file, dir) {
|
|
2619
2641
|
const rel = (0, node_path.relative)(dir, file);
|
|
2620
2642
|
return rel !== "" && !rel.startsWith("..") && !(0, node_path.isAbsolute)(rel) ? !rel.startsWith(`..${node_path.sep}`) : false;
|
|
@@ -5547,7 +5569,7 @@ async function reconcileWorkspace(workspace, options) {
|
|
|
5547
5569
|
metroPorts: metroPorts(workspace, manifest),
|
|
5548
5570
|
fakes,
|
|
5549
5571
|
credentialFakes,
|
|
5550
|
-
apps: (containers) => appServices(workspace, manifest, containers, credentials, runnables, fakes),
|
|
5572
|
+
apps: (containers) => appServices(workspace, manifest, containers, credentials, runnables, fakes, credentialFakes),
|
|
5551
5573
|
...options.start === void 0 ? {} : { start: options.start },
|
|
5552
5574
|
...options.progress ? { progress: options.progress } : {}
|
|
5553
5575
|
});
|
|
@@ -5644,11 +5666,12 @@ function dockerfileOf(appName, path) {
|
|
|
5644
5666
|
* surface resolved to its `*.localhost` host on the edge's port, which the
|
|
5645
5667
|
* rewrite to the compose network then turned into an address nothing answers.
|
|
5646
5668
|
*/
|
|
5647
|
-
function localPlan(workspace, manifest, fakes = {}) {
|
|
5669
|
+
function localPlan(workspace, manifest, fakes = {}, credentialFakes = {}) {
|
|
5648
5670
|
return planFor(manifest, workspace.stages.local, (0, _geekmidas_manifest.provisionOrder)(manifest), {
|
|
5649
5671
|
localStage: workspace.stages.local,
|
|
5650
5672
|
...backendsOf(workspace),
|
|
5651
5673
|
fakes,
|
|
5674
|
+
credentialFakes,
|
|
5652
5675
|
edge: false
|
|
5653
5676
|
});
|
|
5654
5677
|
}
|
|
@@ -5711,8 +5734,12 @@ function networkEnv(plan, options, hostOf = (container) => container) {
|
|
|
5711
5734
|
*
|
|
5712
5735
|
* One hop: a surface an app calls is reached over HTTP, so its URL is the
|
|
5713
5736
|
* app's business and its database is not. A site also gets the public
|
|
5714
|
-
* variant of each key its bundle inlines (`NEXT_PUBLIC_API_URL`)
|
|
5715
|
-
*
|
|
5737
|
+
* variant of each key its bundle inlines (`NEXT_PUBLIC_API_URL`).
|
|
5738
|
+
*
|
|
5739
|
+
* A surface's process runs its own endpoints and nothing else. A Worker's
|
|
5740
|
+
* crons, queue consumers and subscribers run in the worker's own process
|
|
5741
|
+
* (`workerEnvKeys`), so no surface is handed a worker's edges — however its
|
|
5742
|
+
* endpoints were found.
|
|
5716
5743
|
*
|
|
5717
5744
|
* `undefined` for an app no declaration describes, which gets nothing but its
|
|
5718
5745
|
* port.
|
|
@@ -5726,20 +5753,7 @@ function appEnvKeys(manifest, appName, runnables = {}) {
|
|
|
5726
5753
|
...declaration.requires ?? [],
|
|
5727
5754
|
...declaration.kind === "rest-api" ? declaration.endpoints.flatMap((endpoint) => endpoint.requires ?? []) : []
|
|
5728
5755
|
]);
|
|
5729
|
-
|
|
5730
|
-
if (declaration.kind === "rest-api" && declaration.endpoints.length === 0) {
|
|
5731
|
-
const runsWorkers = Object.values(manifest).some((other) => other.kind === "worker");
|
|
5732
|
-
for (const [otherId, other] of Object.entries(manifest)) {
|
|
5733
|
-
if (other.kind !== "worker") continue;
|
|
5734
|
-
edges.push(...(0, _geekmidas_manifest.dependenciesOf)(other).map((edge) => edge.target), ...runnables[otherId] ?? []);
|
|
5735
|
-
keys.add("EVENT_PUBLISHER_CONNECTION_STRING");
|
|
5736
|
-
}
|
|
5737
|
-
if (runsWorkers) for (const other of Object.values(manifest)) {
|
|
5738
|
-
if (other.kind !== "queue" && other.kind !== "topic") continue;
|
|
5739
|
-
for (const key of other.provides ?? []) keys.add(key);
|
|
5740
|
-
}
|
|
5741
|
-
}
|
|
5742
|
-
addEdgeKeys(manifest, edges, keys);
|
|
5756
|
+
addEdgeKeys(manifest, [...(0, _geekmidas_manifest.dependenciesOf)(declaration).map((edge) => edge.target), ...runnables[id] ?? []], keys);
|
|
5743
5757
|
if (declaration.kind === "site" || declaration.kind === "mobile-app") {
|
|
5744
5758
|
for (const key of _geekmidas_manifest.TELEMETRY_KEYS) keys.delete(key);
|
|
5745
5759
|
for (const key of Object.keys((0, _geekmidas_manifest.publicEnvFor)(declaration, manifest))) keys.add(key);
|
|
@@ -5748,10 +5762,9 @@ function appEnvKeys(manifest, appName, runnables = {}) {
|
|
|
5748
5762
|
}
|
|
5749
5763
|
/**
|
|
5750
5764
|
* The keys a Worker's own process reads: what the worker and everything built
|
|
5751
|
-
* from it declared an edge to
|
|
5752
|
-
*
|
|
5753
|
-
*
|
|
5754
|
-
* process that runs them is handed each carrier's.
|
|
5765
|
+
* from it declared an edge to — the queues its consumers drain and the topics
|
|
5766
|
+
* its subscribers are bound to among them (see `DiscoverOptions.runnables`) —
|
|
5767
|
+
* and the broker its crons schedule through.
|
|
5755
5768
|
*
|
|
5756
5769
|
* `undefined` when no worker has that id.
|
|
5757
5770
|
*/
|
|
@@ -5763,10 +5776,6 @@ function workerEnvKeys(manifest, workerId, runnables = {}) {
|
|
|
5763
5776
|
...declaration.requires ?? [],
|
|
5764
5777
|
"EVENT_PUBLISHER_CONNECTION_STRING"
|
|
5765
5778
|
]);
|
|
5766
|
-
for (const other of Object.values(manifest)) {
|
|
5767
|
-
if (other.kind !== "queue" && other.kind !== "topic") continue;
|
|
5768
|
-
for (const key of other.provides ?? []) keys.add(key);
|
|
5769
|
-
}
|
|
5770
5779
|
addEdgeKeys(manifest, [...(0, _geekmidas_manifest.dependenciesOf)(declaration).map((edge) => edge.target), ...runnables[workerId] ?? []], keys);
|
|
5771
5780
|
return keys;
|
|
5772
5781
|
}
|
|
@@ -5790,8 +5799,8 @@ function addEdgeKeys(manifest, edges, keys) {
|
|
|
5790
5799
|
}
|
|
5791
5800
|
}
|
|
5792
5801
|
/** One compose service per app the workspace runs, behind the apps profile. */
|
|
5793
|
-
function appServices(workspace, manifest, containers, credentials, runnables = {}, fakes = {}) {
|
|
5794
|
-
const plan = localPlan(workspace, manifest, fakes);
|
|
5802
|
+
function appServices(workspace, manifest, containers, credentials, runnables = {}, fakes = {}, credentialFakes = {}) {
|
|
5803
|
+
const plan = localPlan(workspace, manifest, fakes, credentialFakes);
|
|
5795
5804
|
const derivation = {
|
|
5796
5805
|
project: workspace.name,
|
|
5797
5806
|
credentials,
|
|
@@ -7303,7 +7312,7 @@ async function createDnsProvider(options) {
|
|
|
7303
7312
|
});
|
|
7304
7313
|
}
|
|
7305
7314
|
if (provider === "godaddy") {
|
|
7306
|
-
const { GoDaddyProvider } = await Promise.resolve().then(() => require("./GoDaddyProvider-
|
|
7315
|
+
const { GoDaddyProvider } = await Promise.resolve().then(() => require("./GoDaddyProvider-Cr9Uvqyz.cjs"));
|
|
7307
7316
|
return new GoDaddyProvider(options.godaddy ?? {});
|
|
7308
7317
|
}
|
|
7309
7318
|
if (provider === "cloudflare") throw new DnsProviderNotImplemented("cloudflare");
|
|
@@ -8680,6 +8689,12 @@ Object.defineProperty(exports, "isTelemetryKey", {
|
|
|
8680
8689
|
return isTelemetryKey;
|
|
8681
8690
|
}
|
|
8682
8691
|
});
|
|
8692
|
+
Object.defineProperty(exports, "isUnder", {
|
|
8693
|
+
enumerable: true,
|
|
8694
|
+
get: function() {
|
|
8695
|
+
return isUnder;
|
|
8696
|
+
}
|
|
8697
|
+
});
|
|
8683
8698
|
Object.defineProperty(exports, "keystoreProject", {
|
|
8684
8699
|
enumerable: true,
|
|
8685
8700
|
get: function() {
|
|
@@ -9119,4 +9134,4 @@ Object.defineProperty(exports, "workspace_exports", {
|
|
|
9119
9134
|
}
|
|
9120
9135
|
});
|
|
9121
9136
|
|
|
9122
|
-
//# sourceMappingURL=seeds-
|
|
9137
|
+
//# sourceMappingURL=seeds-DkcKQ_F8.cjs.map
|