@geekmidas/cli 10.0.0-alpha.104 → 10.0.0-alpha.106
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/{GoDaddyProvider-dezqtUth.cjs → GoDaddyProvider-BesL1P15.cjs} +2 -2
- package/dist/{GoDaddyProvider-dezqtUth.cjs.map → GoDaddyProvider-BesL1P15.cjs.map} +1 -1
- package/dist/{GoDaddyProvider-CuPEbbjl.mjs → GoDaddyProvider-DufGBcDt.mjs} +2 -2
- package/dist/{GoDaddyProvider-CuPEbbjl.mjs.map → GoDaddyProvider-DufGBcDt.mjs.map} +1 -1
- package/dist/{LegacyStateStore-Bc8FnHEB.mjs → LegacyStateStore-1kOwqcd_.mjs} +3 -3
- package/dist/{LegacyStateStore-Bc8FnHEB.mjs.map → LegacyStateStore-1kOwqcd_.mjs.map} +1 -1
- package/dist/{LegacyStateStore-ecxYpm9-.cjs → LegacyStateStore-aFp6-7im.cjs} +3 -3
- package/dist/{LegacyStateStore-ecxYpm9-.cjs.map → LegacyStateStore-aFp6-7im.cjs.map} +1 -1
- package/dist/{LocalStateStore-wSKMDDh5.mjs → LocalStateStore-DFGsiLDy.mjs} +2 -2
- package/dist/{LocalStateStore-wSKMDDh5.mjs.map → LocalStateStore-DFGsiLDy.mjs.map} +1 -1
- package/dist/{LocalStateStore-Sf4B6kUn.cjs → LocalStateStore-Fo33UPTI.cjs} +2 -2
- package/dist/{LocalStateStore-Sf4B6kUn.cjs.map → LocalStateStore-Fo33UPTI.cjs.map} +1 -1
- package/dist/{S3StateStore-BPlVpTfg.mjs → S3StateStore-BlwEPivO.mjs} +2 -2
- package/dist/{S3StateStore-BPlVpTfg.mjs.map → S3StateStore-BlwEPivO.mjs.map} +1 -1
- package/dist/{S3StateStore-DQYjsYBl.cjs → S3StateStore-ZWXXuNQp.cjs} +2 -2
- package/dist/{S3StateStore-DQYjsYBl.cjs.map → S3StateStore-ZWXXuNQp.cjs.map} +1 -1
- package/dist/{SSMStateStore-P9OMZHkp.cjs → SSMStateStore-D5ej5j5M.cjs} +2 -2
- package/dist/{SSMStateStore-P9OMZHkp.cjs.map → SSMStateStore-D5ej5j5M.cjs.map} +1 -1
- package/dist/{SSMStateStore-De2PY12p.mjs → SSMStateStore-DG9h2iVY.mjs} +2 -2
- package/dist/{SSMStateStore-De2PY12p.mjs.map → SSMStateStore-DG9h2iVY.mjs.map} +1 -1
- package/dist/{add-Dgdsb3ox.mjs → add-1VSxmKnf.mjs} +3 -3
- package/dist/{add-Dgdsb3ox.mjs.map → add-1VSxmKnf.mjs.map} +1 -1
- package/dist/{add-C_lp7-oD.cjs → add-B9IgkvTU.cjs} +3 -3
- package/dist/{add-C_lp7-oD.cjs.map → add-B9IgkvTU.cjs.map} +1 -1
- package/dist/{appPorts-C9z9Pzn9.mjs → appPorts-BoXMwolc.mjs} +32 -6
- package/dist/appPorts-BoXMwolc.mjs.map +1 -0
- package/dist/{appPorts-Cu79hJF6.cjs → appPorts-IW-OZmRi.cjs} +37 -5
- package/dist/appPorts-IW-OZmRi.cjs.map +1 -0
- package/dist/{bundler-DBTA8gXs.cjs → bundler-BBDrSnvE.cjs} +5 -5
- package/dist/{bundler-DBTA8gXs.cjs.map → bundler-BBDrSnvE.cjs.map} +1 -1
- package/dist/{bundler-DVPoeMRa.mjs → bundler-By29I7km.mjs} +5 -5
- package/dist/{bundler-DVPoeMRa.mjs.map → bundler-By29I7km.mjs.map} +1 -1
- package/dist/{cli-D7FyFbeC.cjs → cli-Btfl8J6K.cjs} +2 -2
- package/dist/{cli-D7FyFbeC.cjs.map → cli-Btfl8J6K.cjs.map} +1 -1
- package/dist/{cli-CGXOvWRP.mjs → cli-D-ZAyAub.mjs} +2 -2
- package/dist/{cli-CGXOvWRP.mjs.map → cli-D-ZAyAub.mjs.map} +1 -1
- package/dist/{compose-B8ND6s9C.mjs → compose-C-lnkCAT.mjs} +3 -3
- package/dist/{compose-B8ND6s9C.mjs.map → compose-C-lnkCAT.mjs.map} +1 -1
- package/dist/{compose-qbPKKAMC.cjs → compose-daUOp1bm.cjs} +3 -3
- package/dist/{compose-qbPKKAMC.cjs.map → compose-daUOp1bm.cjs.map} +1 -1
- package/dist/deploy/public.cjs +6 -6
- package/dist/deploy/public.mjs +6 -6
- package/dist/{deploy-yLGEWuam.mjs → deploy-T3TwqzKf.mjs} +5 -5
- package/dist/{deploy-yLGEWuam.mjs.map → deploy-T3TwqzKf.mjs.map} +1 -1
- package/dist/{deploy-Bsxl6nyG.cjs → deploy-V43Rbboj.cjs} +5 -5
- package/dist/{deploy-Bsxl6nyG.cjs.map → deploy-V43Rbboj.cjs.map} +1 -1
- package/dist/{dns-BQrhafpk.mjs → dns-AosA2wwP.mjs} +2 -2
- package/dist/{dns-BQrhafpk.mjs.map → dns-AosA2wwP.mjs.map} +1 -1
- package/dist/{dns-BUUEztBH.cjs → dns-BfNzYlpR.cjs} +2 -2
- package/dist/{dns-BUUEztBH.cjs.map → dns-BfNzYlpR.cjs.map} +1 -1
- package/dist/{dokploy-CCnoXmGV.cjs → dokploy-COnyBUBW.cjs} +2 -2
- package/dist/{dokploy-CCnoXmGV.cjs.map → dokploy-COnyBUBW.cjs.map} +1 -1
- package/dist/{dokploy-BuIvCaE1.mjs → dokploy-CaLl5YmO.mjs} +2 -2
- package/dist/{dokploy-BuIvCaE1.mjs.map → dokploy-CaLl5YmO.mjs.map} +1 -1
- package/dist/{encryption-BFs3ItV9.mjs → encryption-BqSWtrXU.mjs} +2 -2
- package/dist/{encryption-BFs3ItV9.mjs.map → encryption-BqSWtrXU.mjs.map} +1 -1
- package/dist/{encryption-2KOlWvfq.cjs → encryption-CJdgXVFM.cjs} +2 -2
- package/dist/{encryption-2KOlWvfq.cjs.map → encryption-CJdgXVFM.cjs.map} +1 -1
- package/dist/{engine-vvr2EpTb.mjs → engine-BMM2Vy26.mjs} +3 -3
- package/dist/{engine-vvr2EpTb.mjs.map → engine-BMM2Vy26.mjs.map} +1 -1
- package/dist/{engine-Bx_ea2_k.cjs → engine-DjI9DFDW.cjs} +3 -3
- package/dist/{engine-Bx_ea2_k.cjs.map → engine-DjI9DFDW.cjs.map} +1 -1
- package/dist/{github-BM6afosB.cjs → github-MYWre3_E.cjs} +4 -4
- package/dist/{github-BM6afosB.cjs.map → github-MYWre3_E.cjs.map} +1 -1
- package/dist/{github-DuXBKTvr.mjs → github-SViQU_St.mjs} +4 -4
- package/dist/{github-DuXBKTvr.mjs.map → github-SViQU_St.mjs.map} +1 -1
- package/dist/index.cjs +50 -50
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +50 -50
- package/dist/index.mjs.map +1 -1
- package/dist/{migrate-CQal4P1q.mjs → migrate-BNyMi8h5.mjs} +2 -2
- package/dist/{migrate-CQal4P1q.mjs.map → migrate-BNyMi8h5.mjs.map} +1 -1
- package/dist/{migrate-DXVzuw-s.cjs → migrate-CNQp-SAH.cjs} +2 -2
- package/dist/{migrate-DXVzuw-s.cjs.map → migrate-CNQp-SAH.cjs.map} +1 -1
- package/dist/{migrate-BQfq48xK.cjs → migrate-DwsOYzmN.cjs} +2 -2
- package/dist/{migrate-BQfq48xK.cjs.map → migrate-DwsOYzmN.cjs.map} +1 -1
- package/dist/{migrate-BlLFYSIx.mjs → migrate-H2vGmQ3l.mjs} +2 -2
- package/dist/{migrate-BlLFYSIx.mjs.map → migrate-H2vGmQ3l.mjs.map} +1 -1
- package/dist/{ready-DU7wvxWk.cjs → ready-BMFjxBYA.cjs} +3 -2
- package/dist/ready-BMFjxBYA.cjs.map +1 -0
- package/dist/{ready-CVNE5Pix.mjs → ready-CIt5SOtg.mjs} +3 -2
- package/dist/ready-CIt5SOtg.mjs.map +1 -0
- package/dist/{resolve-De9vfAnN.mjs → resolve-C2vVcD64.mjs} +3 -3
- package/dist/{resolve-De9vfAnN.mjs.map → resolve-C2vVcD64.mjs.map} +1 -1
- package/dist/{resolve-By_cw893.cjs → resolve-ClAnYHo-.cjs} +3 -3
- package/dist/{resolve-By_cw893.cjs.map → resolve-ClAnYHo-.cjs.map} +1 -1
- package/dist/{rollback-YCj4_q9l.mjs → rollback-BrBL9j9s.mjs} +4 -4
- package/dist/{rollback-YCj4_q9l.mjs.map → rollback-BrBL9j9s.mjs.map} +1 -1
- package/dist/{rollback-dkinZaOv.cjs → rollback-CRVwGkEl.cjs} +4 -4
- package/dist/{rollback-dkinZaOv.cjs.map → rollback-CRVwGkEl.cjs.map} +1 -1
- package/dist/{seeds-DZGuovWF.mjs → seeds-C1v4ZOro.mjs} +42 -12
- package/dist/seeds-C1v4ZOro.mjs.map +1 -0
- package/dist/{seeds-CjBwLvWY.cjs → seeds-RTQPjA4K.cjs} +41 -11
- package/dist/seeds-RTQPjA4K.cjs.map +1 -0
- package/dist/{sniffer-bo0KeZsK.mjs → sniffer-CLJ3cB3b.mjs} +6 -6
- package/dist/{sniffer-bo0KeZsK.mjs.map → sniffer-CLJ3cB3b.mjs.map} +1 -1
- package/dist/{sniffer-t0NsMNNP.cjs → sniffer-Cy1pb4hg.cjs} +6 -6
- package/dist/{sniffer-t0NsMNNP.cjs.map → sniffer-Cy1pb4hg.cjs.map} +1 -1
- package/dist/target/public.cjs +1 -1
- package/dist/target/public.mjs +1 -1
- package/dist/vitest.cjs +1 -1
- package/dist/vitest.mjs +1 -1
- package/package.json +15 -15
- package/dist/appPorts-C9z9Pzn9.mjs.map +0 -1
- package/dist/appPorts-Cu79hJF6.cjs.map +0 -1
- package/dist/ready-CVNE5Pix.mjs.map +0 -1
- package/dist/ready-DU7wvxWk.cjs.map +0 -1
- package/dist/seeds-CjBwLvWY.cjs.map +0 -1
- package/dist/seeds-DZGuovWF.mjs.map +0 -1
|
@@ -8,7 +8,7 @@ const require_identity = require("./identity-CbLfgQNT.cjs");
|
|
|
8
8
|
const require_EndpointGenerator = require("./EndpointGenerator-BwbYTMtB.cjs");
|
|
9
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-ClAnYHo-.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");
|
|
@@ -1033,6 +1033,10 @@ function planFor(manifest, stage, order, options = {}) {
|
|
|
1033
1033
|
} } : {},
|
|
1034
1034
|
...declaration.kind === "external-api" && !fake ? { url: declaration.url } : {},
|
|
1035
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
|
+
} } : {},
|
|
1036
1040
|
..."of" in declaration && !detached ? { of: declaration.of } : {},
|
|
1037
1041
|
..."schema" in declaration && declaration.schema ? { schema: declaration.schema } : {},
|
|
1038
1042
|
..."version" in declaration && declaration.version ? { version: declaration.version } : {},
|
|
@@ -1552,10 +1556,36 @@ function localKeyring(project, plan, resource) {
|
|
|
1552
1556
|
* A hash of what identifies it, so it is stable, distinct per project, stage
|
|
1553
1557
|
* and construct, and never written to disk as a literal. Deployed this is the
|
|
1554
1558
|
* one kind whose value does *not* come from here — a secret manager generates
|
|
1555
|
-
* 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.
|
|
1556
1561
|
*/
|
|
1557
1562
|
function localSecret(project, plan, resource) {
|
|
1558
|
-
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
|
+
};
|
|
1559
1589
|
}
|
|
1560
1590
|
//#endregion
|
|
1561
1591
|
//#region src/compose/redis.ts
|
|
@@ -1713,8 +1743,8 @@ function redisService(redis) {
|
|
|
1713
1743
|
* master and roles, a bucket's root user. Derived from repo facts alone
|
|
1714
1744
|
* (project, stage, construct id), those passwords were computable by anyone
|
|
1715
1745
|
* who could read the repo.
|
|
1716
|
-
* - **Each `secret` construct's value** — an auth server's signing secret
|
|
1717
|
-
* 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.
|
|
1718
1748
|
* - **Each `encryption` construct's keyring** — one random key and an index
|
|
1719
1749
|
* key. Later keys are added by `gkm encryption:rotate`, never by a deploy.
|
|
1720
1750
|
*
|
|
@@ -1735,7 +1765,7 @@ function withGeneratedSecrets(secrets, manifest) {
|
|
|
1735
1765
|
if (declaration?.kind !== "secret" && declaration?.kind !== "encryption") continue;
|
|
1736
1766
|
const key = declaration.provides?.[0];
|
|
1737
1767
|
if (!key || custom[key]) continue;
|
|
1738
|
-
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);
|
|
1739
1769
|
generated.push(key);
|
|
1740
1770
|
}
|
|
1741
1771
|
const seed = secrets.seed ?? generateSeed();
|
|
@@ -3977,17 +4007,17 @@ async function prepareEntryCredentials(options) {
|
|
|
3977
4007
|
secretsRoot = workspace?.root ?? findSecretsRoot(cwd);
|
|
3978
4008
|
}
|
|
3979
4009
|
if (appName && workspace && options.explicitPort === void 0) {
|
|
3980
|
-
const { assignAppPorts,
|
|
4010
|
+
const { assignAppPorts, describeMove, holderOf, withAppPorts } = await Promise.resolve().then(() => require("./appPorts-IW-OZmRi.cjs")).then((n) => n.appPorts_exports);
|
|
3981
4011
|
const assigned = await assignAppPorts(workspace, [appName], {
|
|
3982
4012
|
free: isPortAvailable,
|
|
3983
4013
|
holder: holderOf
|
|
3984
4014
|
});
|
|
3985
|
-
for (const
|
|
4015
|
+
for (const move of assigned.moved) logger$2.log(describeMove(move));
|
|
3986
4016
|
workspace = withAppPorts(workspace, assigned.ports);
|
|
3987
4017
|
workspaceAppPort = assigned.ports[appName] ?? workspaceAppPort;
|
|
3988
4018
|
}
|
|
3989
4019
|
if (appName) {
|
|
3990
|
-
const { APP_TAG_ENV, appTag } = await Promise.resolve().then(() => require("./appPorts-
|
|
4020
|
+
const { APP_TAG_ENV, appTag } = await Promise.resolve().then(() => require("./appPorts-IW-OZmRi.cjs")).then((n) => n.appPorts_exports);
|
|
3991
4021
|
process.env[APP_TAG_ENV] = appTag(secretsRoot, appName);
|
|
3992
4022
|
}
|
|
3993
4023
|
const resolvedPort = options.explicitPort ?? workspaceAppPort ?? 3e3;
|
|
@@ -7282,7 +7312,7 @@ async function createDnsProvider(options) {
|
|
|
7282
7312
|
});
|
|
7283
7313
|
}
|
|
7284
7314
|
if (provider === "godaddy") {
|
|
7285
|
-
const { GoDaddyProvider } = await Promise.resolve().then(() => require("./GoDaddyProvider-
|
|
7315
|
+
const { GoDaddyProvider } = await Promise.resolve().then(() => require("./GoDaddyProvider-BesL1P15.cjs"));
|
|
7286
7316
|
return new GoDaddyProvider(options.godaddy ?? {});
|
|
7287
7317
|
}
|
|
7288
7318
|
if (provider === "cloudflare") throw new DnsProviderNotImplemented("cloudflare");
|
|
@@ -9104,4 +9134,4 @@ Object.defineProperty(exports, "workspace_exports", {
|
|
|
9104
9134
|
}
|
|
9105
9135
|
});
|
|
9106
9136
|
|
|
9107
|
-
//# sourceMappingURL=seeds-
|
|
9137
|
+
//# sourceMappingURL=seeds-RTQPjA4K.cjs.map
|