@geekmidas/cli 10.0.0-alpha.102 → 10.0.0-alpha.104
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-u9MF-Dqk.mjs → GoDaddyProvider-CuPEbbjl.mjs} +2 -2
- package/dist/{GoDaddyProvider-u9MF-Dqk.mjs.map → GoDaddyProvider-CuPEbbjl.mjs.map} +1 -1
- package/dist/{GoDaddyProvider-BOuLf_Py.cjs → GoDaddyProvider-dezqtUth.cjs} +2 -2
- package/dist/{GoDaddyProvider-BOuLf_Py.cjs.map → GoDaddyProvider-dezqtUth.cjs.map} +1 -1
- package/dist/{LegacyStateStore-vhkx7Bbq.mjs → LegacyStateStore-Bc8FnHEB.mjs} +3 -3
- package/dist/{LegacyStateStore-vhkx7Bbq.mjs.map → LegacyStateStore-Bc8FnHEB.mjs.map} +1 -1
- package/dist/{LegacyStateStore-DWmHGNgH.cjs → LegacyStateStore-ecxYpm9-.cjs} +3 -3
- package/dist/{LegacyStateStore-DWmHGNgH.cjs.map → LegacyStateStore-ecxYpm9-.cjs.map} +1 -1
- package/dist/{LocalStateStore-BVKDADoG.cjs → LocalStateStore-Sf4B6kUn.cjs} +2 -2
- package/dist/{LocalStateStore-BVKDADoG.cjs.map → LocalStateStore-Sf4B6kUn.cjs.map} +1 -1
- package/dist/{LocalStateStore-FVsg0UoM.mjs → LocalStateStore-wSKMDDh5.mjs} +2 -2
- package/dist/{LocalStateStore-FVsg0UoM.mjs.map → LocalStateStore-wSKMDDh5.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-B8seZUsw.mjs → S3StateStore-BPlVpTfg.mjs} +2 -2
- package/dist/{S3StateStore-B8seZUsw.mjs.map → S3StateStore-BPlVpTfg.mjs.map} +1 -1
- package/dist/{S3StateStore-B_2gE9Un.cjs → S3StateStore-DQYjsYBl.cjs} +2 -2
- package/dist/{S3StateStore-B_2gE9Un.cjs.map → S3StateStore-DQYjsYBl.cjs.map} +1 -1
- package/dist/{SSMStateStore-DGTbBomw.mjs → SSMStateStore-De2PY12p.mjs} +2 -2
- package/dist/{SSMStateStore-DGTbBomw.mjs.map → SSMStateStore-De2PY12p.mjs.map} +1 -1
- package/dist/{SSMStateStore-CTDEI5Bi.cjs → SSMStateStore-P9OMZHkp.cjs} +2 -2
- package/dist/{SSMStateStore-CTDEI5Bi.cjs.map → SSMStateStore-P9OMZHkp.cjs.map} +1 -1
- package/dist/{SubscriberGenerator-BlIOdbi-.cjs → SubscriberGenerator-CeH7wbYt.cjs} +93 -12
- package/dist/SubscriberGenerator-CeH7wbYt.cjs.map +1 -0
- package/dist/{SubscriberGenerator-1-IsjIwF.mjs → SubscriberGenerator-DHnIYwUU.mjs} +82 -13
- package/dist/SubscriberGenerator-DHnIYwUU.mjs.map +1 -0
- package/dist/{add-BB2tLVc2.cjs → add-C_lp7-oD.cjs} +8 -9
- package/dist/add-C_lp7-oD.cjs.map +1 -0
- package/dist/{add-CIbhGE5v.mjs → add-Dgdsb3ox.mjs} +8 -9
- package/dist/add-Dgdsb3ox.mjs.map +1 -0
- package/dist/{bundler-Ba6BER3w.cjs → bundler-DBTA8gXs.cjs} +5 -5
- package/dist/{bundler-Ba6BER3w.cjs.map → bundler-DBTA8gXs.cjs.map} +1 -1
- package/dist/{bundler-CHjRYVKh.mjs → bundler-DVPoeMRa.mjs} +5 -5
- package/dist/{bundler-CHjRYVKh.mjs.map → bundler-DVPoeMRa.mjs.map} +1 -1
- package/dist/{cli-DOlkhrsh.mjs → cli-CGXOvWRP.mjs} +3 -3
- package/dist/{cli-DOlkhrsh.mjs.map → cli-CGXOvWRP.mjs.map} +1 -1
- package/dist/{cli-CtlqYRlN.cjs → cli-D7FyFbeC.cjs} +3 -3
- package/dist/{cli-CtlqYRlN.cjs.map → cli-D7FyFbeC.cjs.map} +1 -1
- package/dist/{compose-FDP_TaFt.mjs → compose-B8ND6s9C.mjs} +14 -11
- package/dist/{compose-FDP_TaFt.mjs.map → compose-B8ND6s9C.mjs.map} +1 -1
- package/dist/{compose-uAWLy-nR.cjs → compose-qbPKKAMC.cjs} +14 -11
- package/dist/compose-qbPKKAMC.cjs.map +1 -0
- 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-DUUc3jV9.cjs → deploy-Bsxl6nyG.cjs} +8 -8
- package/dist/{deploy-DUUc3jV9.cjs.map → deploy-Bsxl6nyG.cjs.map} +1 -1
- package/dist/{deploy-DgZxTnGS.mjs → deploy-yLGEWuam.mjs} +8 -8
- package/dist/{deploy-DgZxTnGS.mjs.map → deploy-yLGEWuam.mjs.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-DDDCfj75.mjs → dns-BQrhafpk.mjs} +2 -2
- package/dist/{dns-DDDCfj75.mjs.map → dns-BQrhafpk.mjs.map} +1 -1
- package/dist/{dns-DnE_02tB.cjs → dns-BUUEztBH.cjs} +2 -2
- package/dist/{dns-DnE_02tB.cjs.map → dns-BUUEztBH.cjs.map} +1 -1
- package/dist/{dokploy-DBlGSdnb.mjs → dokploy-BuIvCaE1.mjs} +2 -2
- package/dist/{dokploy-DBlGSdnb.mjs.map → dokploy-BuIvCaE1.mjs.map} +1 -1
- package/dist/{dokploy-BrfdeVEu.cjs → dokploy-CCnoXmGV.cjs} +2 -2
- package/dist/{dokploy-BrfdeVEu.cjs.map → dokploy-CCnoXmGV.cjs.map} +1 -1
- package/dist/{drivers-C08LL4E8.mjs → drivers-D11JHxrD.mjs} +2 -2
- package/dist/{drivers-C08LL4E8.mjs.map → drivers-D11JHxrD.mjs.map} +1 -1
- package/dist/{drivers-BLU1fNs_.cjs → drivers-GKaA6ITM.cjs} +2 -2
- package/dist/{drivers-BLU1fNs_.cjs.map → drivers-GKaA6ITM.cjs.map} +1 -1
- package/dist/{encryption-CeW3xpE1.cjs → encryption-2KOlWvfq.cjs} +2 -2
- package/dist/{encryption-CeW3xpE1.cjs.map → encryption-2KOlWvfq.cjs.map} +1 -1
- package/dist/{encryption-DC8zsh2s.mjs → encryption-BFs3ItV9.mjs} +2 -2
- package/dist/{encryption-DC8zsh2s.mjs.map → encryption-BFs3ItV9.mjs.map} +1 -1
- package/dist/{engine-BXxvcxVq.cjs → engine-Bx_ea2_k.cjs} +6 -5
- package/dist/engine-Bx_ea2_k.cjs.map +1 -0
- package/dist/{engine-z0UClzE9.mjs → engine-vvr2EpTb.mjs} +6 -5
- package/dist/engine-vvr2EpTb.mjs.map +1 -0
- package/dist/{github-DWoFgxtl.cjs → github-BM6afosB.cjs} +5 -5
- package/dist/{github-DWoFgxtl.cjs.map → github-BM6afosB.cjs.map} +1 -1
- package/dist/{github-DJgO5z37.mjs → github-DuXBKTvr.mjs} +5 -5
- package/dist/{github-DJgO5z37.mjs.map → github-DuXBKTvr.mjs.map} +1 -1
- package/dist/index.cjs +185 -102
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +186 -103
- package/dist/index.mjs.map +1 -1
- package/dist/{migrate-B1OjPwUY.cjs → migrate-BQfq48xK.cjs} +2 -2
- package/dist/{migrate-B1OjPwUY.cjs.map → migrate-BQfq48xK.cjs.map} +1 -1
- package/dist/{migrate-DoI2hWNH.mjs → migrate-BlLFYSIx.mjs} +2 -2
- package/dist/{migrate-DoI2hWNH.mjs.map → migrate-BlLFYSIx.mjs.map} +1 -1
- package/dist/{migrate-DIVxoju6.mjs → migrate-CQal4P1q.mjs} +3 -3
- package/dist/{migrate-DIVxoju6.mjs.map → migrate-CQal4P1q.mjs.map} +1 -1
- package/dist/{migrate-CWSCkzu3.cjs → migrate-DXVzuw-s.cjs} +3 -3
- package/dist/{migrate-CWSCkzu3.cjs.map → migrate-DXVzuw-s.cjs.map} +1 -1
- package/dist/openapi.cjs +2 -2
- package/dist/openapi.mjs +2 -2
- package/dist/{ready-CzHNHhI6.mjs → ready-CVNE5Pix.mjs} +6 -6
- package/dist/{ready-CzHNHhI6.mjs.map → ready-CVNE5Pix.mjs.map} +1 -1
- package/dist/{ready-BtxiI7Qb.cjs → ready-DU7wvxWk.cjs} +6 -6
- package/dist/{ready-BtxiI7Qb.cjs.map → ready-DU7wvxWk.cjs.map} +1 -1
- package/dist/reconcile/public.cjs +1 -1
- package/dist/reconcile/public.mjs +1 -1
- package/dist/{resolve-WAwYMN6q.cjs → resolve-By_cw893.cjs} +3 -3
- package/dist/{resolve-WAwYMN6q.cjs.map → resolve-By_cw893.cjs.map} +1 -1
- package/dist/{resolve-pmXIdi9j.mjs → resolve-De9vfAnN.mjs} +3 -3
- package/dist/{resolve-pmXIdi9j.mjs.map → resolve-De9vfAnN.mjs.map} +1 -1
- package/dist/{rollback-CLtwbByg.mjs → rollback-YCj4_q9l.mjs} +4 -4
- package/dist/{rollback-CLtwbByg.mjs.map → rollback-YCj4_q9l.mjs.map} +1 -1
- package/dist/{rollback-Cz8F9xSB.cjs → rollback-dkinZaOv.cjs} +4 -4
- package/dist/{rollback-Cz8F9xSB.cjs.map → rollback-dkinZaOv.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-Dk4WHhjU.cjs → seeds-CjBwLvWY.cjs} +40 -48
- package/dist/seeds-CjBwLvWY.cjs.map +1 -0
- package/dist/{seeds-BHKUAExH.mjs → seeds-DZGuovWF.mjs} +35 -49
- package/dist/seeds-DZGuovWF.mjs.map +1 -0
- package/dist/{sniffer-CaXl51vO.mjs → sniffer-bo0KeZsK.mjs} +7 -7
- package/dist/{sniffer-CaXl51vO.mjs.map → sniffer-bo0KeZsK.mjs.map} +1 -1
- package/dist/{sniffer-BjBZ01PE.cjs → sniffer-t0NsMNNP.cjs} +7 -7
- package/dist/{sniffer-BjBZ01PE.cjs.map → sniffer-t0NsMNNP.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/SubscriberGenerator-1-IsjIwF.mjs.map +0 -1
- package/dist/SubscriberGenerator-BlIOdbi-.cjs.map +0 -1
- package/dist/add-BB2tLVc2.cjs.map +0 -1
- package/dist/add-CIbhGE5v.mjs.map +0 -1
- package/dist/compose-uAWLy-nR.cjs.map +0 -1
- package/dist/engine-BXxvcxVq.cjs.map +0 -1
- package/dist/engine-z0UClzE9.mjs.map +0 -1
- package/dist/seeds-BHKUAExH.mjs.map +0 -1
- package/dist/seeds-Dk4WHhjU.cjs.map +0 -1
package/dist/index.cjs
CHANGED
|
@@ -4,27 +4,27 @@ const require_rolldown_runtime = require("./rolldown-runtime-C0BPl7ul.cjs");
|
|
|
4
4
|
const require_errors = require("./errors-DMC4Umsb.cjs");
|
|
5
5
|
const require_run = require("./run-fVZ-rLnc.cjs");
|
|
6
6
|
const require_credentials = require("./credentials-Zqr3QQYB.cjs");
|
|
7
|
-
const require_compose = require("./compose-
|
|
7
|
+
const require_compose = require("./compose-qbPKKAMC.cjs");
|
|
8
8
|
const require_workspace = require("./workspace-BwqQnool.cjs");
|
|
9
|
-
const require_dns = require("./dns-
|
|
10
|
-
const require_seeds = require("./seeds-
|
|
9
|
+
const require_dns = require("./dns-BUUEztBH.cjs");
|
|
10
|
+
const require_seeds = require("./seeds-CjBwLvWY.cjs");
|
|
11
11
|
const require_derive = require("./derive-DAbo49sm.cjs");
|
|
12
|
-
const require_SubscriberGenerator = require("./SubscriberGenerator-
|
|
12
|
+
const require_SubscriberGenerator = require("./SubscriberGenerator-CeH7wbYt.cjs");
|
|
13
13
|
const require_identity = require("./identity-CbLfgQNT.cjs");
|
|
14
|
-
const require_EndpointGenerator = require("./EndpointGenerator-
|
|
15
|
-
const require_discover = require("./discover-
|
|
14
|
+
const require_EndpointGenerator = require("./EndpointGenerator-BwbYTMtB.cjs");
|
|
15
|
+
const require_discover = require("./discover-Bsr7HjqJ.cjs");
|
|
16
16
|
const require_config = require("./config.cjs");
|
|
17
|
-
const require_deploy = require("./deploy-
|
|
17
|
+
const require_deploy = require("./deploy-Bsxl6nyG.cjs");
|
|
18
18
|
const require_openapi = require("./openapi.cjs");
|
|
19
19
|
const require_appPorts = require("./appPorts-Cu79hJF6.cjs");
|
|
20
|
-
const require_drivers = require("./drivers-
|
|
20
|
+
const require_drivers = require("./drivers-GKaA6ITM.cjs");
|
|
21
21
|
const require_emit = require("./emit-Dmc1nvdS.cjs");
|
|
22
22
|
const require_local = require("./local-DNhnkugT.cjs");
|
|
23
|
-
const require_sniffer = require("./sniffer-
|
|
24
|
-
const require_credentialSchemas = require("./credentialSchemas-
|
|
25
|
-
const require_LocalStateStore = require("./LocalStateStore-
|
|
23
|
+
const require_sniffer = require("./sniffer-t0NsMNNP.cjs");
|
|
24
|
+
const require_credentialSchemas = require("./credentialSchemas-D_VUCDUh.cjs");
|
|
25
|
+
const require_LocalStateStore = require("./LocalStateStore-Sf4B6kUn.cjs");
|
|
26
26
|
const require_utils = require("./utils-D2Nk1Nv2.cjs");
|
|
27
|
-
const require_ready = require("./ready-
|
|
27
|
+
const require_ready = require("./ready-DU7wvxWk.cjs");
|
|
28
28
|
let node_path = require("node:path");
|
|
29
29
|
let commander = require("commander");
|
|
30
30
|
let node_process = require("node:process");
|
|
@@ -57,7 +57,7 @@ crypto = require_rolldown_runtime.__toESM(crypto, 1);
|
|
|
57
57
|
let _geekmidas_constructs_functions = require("@geekmidas/constructs/functions");
|
|
58
58
|
let _geekmidas_constructs_topic = require("@geekmidas/constructs/topic");
|
|
59
59
|
//#region package.json
|
|
60
|
-
var version = "10.0.0-alpha.
|
|
60
|
+
var version = "10.0.0-alpha.104";
|
|
61
61
|
//#endregion
|
|
62
62
|
//#region src/prompt.ts
|
|
63
63
|
/**
|
|
@@ -140,7 +140,7 @@ const logger$8 = console;
|
|
|
140
140
|
* Validate Dokploy token by making a test API call
|
|
141
141
|
*/
|
|
142
142
|
async function validateDokployToken(endpoint, token) {
|
|
143
|
-
const { DokployApi } = await Promise.resolve().then(() => require("./sniffer-
|
|
143
|
+
const { DokployApi } = await Promise.resolve().then(() => require("./sniffer-t0NsMNNP.cjs")).then((n) => n.dokploy_api_exports);
|
|
144
144
|
return new DokployApi({
|
|
145
145
|
baseUrl: endpoint,
|
|
146
146
|
token
|
|
@@ -2353,7 +2353,8 @@ async function devCommand(options) {
|
|
|
2353
2353
|
skipBundle: true,
|
|
2354
2354
|
bustCache,
|
|
2355
2355
|
serveEmpty: true,
|
|
2356
|
-
workspaceName: workspace.name
|
|
2356
|
+
workspaceName: workspace.name,
|
|
2357
|
+
workspace
|
|
2357
2358
|
}));
|
|
2358
2359
|
logger$5.log(`🔨 Building ${workspaceAppName ?? "the app"}`);
|
|
2359
2360
|
const initial = await build();
|
|
@@ -2381,8 +2382,9 @@ async function devCommand(options) {
|
|
|
2381
2382
|
}
|
|
2382
2383
|
}
|
|
2383
2384
|
Object.assign(appSecrets, reconciled.env);
|
|
2385
|
+
const declared = reconciled.manifest;
|
|
2384
2386
|
const scoped = require_seeds.scopeTelemetryEnv(appSecrets, {
|
|
2385
|
-
uses:
|
|
2387
|
+
uses: declared !== void 0 && (require_seeds.appTelemetry(declared, workspaceAppName) !== void 0 || (initial.workers ?? []).some((id) => require_seeds.telemetryOf(declared, id) !== void 0)),
|
|
2386
2388
|
serviceName: workspaceAppName,
|
|
2387
2389
|
telemetry: reconciled.env
|
|
2388
2390
|
});
|
|
@@ -2734,9 +2736,9 @@ async function workspaceDevCommand(configured, options) {
|
|
|
2734
2736
|
for (const { id, port } of fakes) logger$5.log(`🎭 ${id} fake: http://localhost:${port}`);
|
|
2735
2737
|
logger$5.log(options.migrate || options.seed ? "🗄️ Migrating the databases" : "🗄️ Checking for pending migrations");
|
|
2736
2738
|
if (options.migrate || options.seed) {
|
|
2737
|
-
const { prepareDevDatabases } = await Promise.resolve().then(() => require("./migrate-
|
|
2739
|
+
const { prepareDevDatabases } = await Promise.resolve().then(() => require("./migrate-DXVzuw-s.cjs"));
|
|
2738
2740
|
await prepareDevDatabases(workspace, reconciled.env, { seed: !!options.seed });
|
|
2739
|
-
} else await Promise.resolve().then(() => require("./migrate-
|
|
2741
|
+
} else await Promise.resolve().then(() => require("./migrate-DXVzuw-s.cjs")).then(({ reportPendingMigrations }) => reportPendingMigrations(workspace, reconciled.env)).catch((error) => {
|
|
2740
2742
|
logger$5.log(`⚠️ Could not check for pending migrations: ${error instanceof Error ? error.message : String(error)}`);
|
|
2741
2743
|
});
|
|
2742
2744
|
const appUrls = {};
|
|
@@ -3472,6 +3474,29 @@ function restApis(declared) {
|
|
|
3472
3474
|
function servedSurface(declared, workspaceRoot, appRoot) {
|
|
3473
3475
|
return restApis(declared).find((d) => (0, node_path.resolve)(workspaceRoot, d.path) === (0, node_path.resolve)(appRoot));
|
|
3474
3476
|
}
|
|
3477
|
+
/**
|
|
3478
|
+
* The declarations one process reaches: the constructs it runs as — a surface,
|
|
3479
|
+
* a worker — what each declared an edge to, and what each runnable it runs
|
|
3480
|
+
* depends on or consumes.
|
|
3481
|
+
*
|
|
3482
|
+
* What decides which drivers its entry registers: a process that reaches no
|
|
3483
|
+
* cache never resolves a cache client because another process in the
|
|
3484
|
+
* workspace does.
|
|
3485
|
+
*/
|
|
3486
|
+
function reachedBy(declared, processes, runnables) {
|
|
3487
|
+
const reached = /* @__PURE__ */ new Set();
|
|
3488
|
+
for (const id of processes) {
|
|
3489
|
+
const declaration = declared[id];
|
|
3490
|
+
if (!declaration) continue;
|
|
3491
|
+
reached.add(id);
|
|
3492
|
+
for (const edge of (0, _geekmidas_manifest.dependenciesOf)(declaration)) reached.add(edge.target);
|
|
3493
|
+
}
|
|
3494
|
+
for (const { construct } of runnables) {
|
|
3495
|
+
for (const id of construct.constructs ?? []) reached.add((0, _geekmidas_manifest.canonicalId)(id));
|
|
3496
|
+
for (const id of require_discover.consumedBy(construct)) reached.add(id);
|
|
3497
|
+
}
|
|
3498
|
+
return Object.fromEntries(Object.entries(declared).filter(([id]) => reached.has(id)));
|
|
3499
|
+
}
|
|
3475
3500
|
//#endregion
|
|
3476
3501
|
//#region src/build/surfaceEntry.ts
|
|
3477
3502
|
/** Whether a construct serves itself, asked of the construct. */
|
|
@@ -3789,7 +3814,7 @@ async function buildApp(input) {
|
|
|
3789
3814
|
...production,
|
|
3790
3815
|
...telemetry ? { telemetry } : {}
|
|
3791
3816
|
});
|
|
3792
|
-
const { bundleServer } = await Promise.resolve().then(() => require("./bundler-
|
|
3817
|
+
const { bundleServer } = await Promise.resolve().then(() => require("./bundler-DBTA8gXs.cjs"));
|
|
3793
3818
|
await bundleServer({
|
|
3794
3819
|
entryPoint,
|
|
3795
3820
|
outputDir: (0, node_path.join)(outputDir, "dist"),
|
|
@@ -3809,7 +3834,6 @@ async function buildApp(input) {
|
|
|
3809
3834
|
appRoot,
|
|
3810
3835
|
databaseApi
|
|
3811
3836
|
});
|
|
3812
|
-
const eventsBackends = require_drivers.eventsBackendsIn(declared, eventsBackend);
|
|
3813
3837
|
const buildContext = {
|
|
3814
3838
|
...derived,
|
|
3815
3839
|
telescope,
|
|
@@ -3818,12 +3842,6 @@ async function buildApp(input) {
|
|
|
3818
3842
|
constructGlobs,
|
|
3819
3843
|
cacheBackend,
|
|
3820
3844
|
emailBackend: "ses",
|
|
3821
|
-
storageDrivers: require_drivers.driversFor({
|
|
3822
|
-
appRoot,
|
|
3823
|
-
cache: require_drivers.cacheBackendsIn(declared, cacheBackend),
|
|
3824
|
-
events: eventsBackends
|
|
3825
|
-
}),
|
|
3826
|
-
eventsBackends,
|
|
3827
3845
|
markOptional: input.markOptional ?? false
|
|
3828
3846
|
};
|
|
3829
3847
|
const endpointGenerator = new require_EndpointGenerator.EndpointGenerator();
|
|
@@ -3842,8 +3860,39 @@ async function buildApp(input) {
|
|
|
3842
3860
|
topicGenerator.load(code, appRoot, bustCache)
|
|
3843
3861
|
]);
|
|
3844
3862
|
const allEndpoints = servedBy(loadedEndpoints, derived.surface);
|
|
3863
|
+
const appName = appNameOf(input);
|
|
3864
|
+
const hosted = require_seeds.workerUnits(input.workspace, declared, background).filter((unit) => unit.app === appName);
|
|
3865
|
+
const hostedIds = new Set(hosted.map((unit) => unit.id));
|
|
3866
|
+
const appRootAbs = (0, node_path.resolve)(appRoot);
|
|
3867
|
+
const hostedHere = (list) => list.filter(({ construct, path }) => construct.owner !== void 0 ? hostedIds.has(construct.owner) : require_seeds.isUnder(path.absolute, appRootAbs));
|
|
3868
|
+
const hostedCrons = hostedHere(allCrons);
|
|
3869
|
+
const hostedQueues = hostedHere(allQueues);
|
|
3870
|
+
const hostedSubscribers = hostedHere(allSubscribers);
|
|
3871
|
+
const servesOnly = Boolean(production?.enabled && derived.surface);
|
|
3872
|
+
const inProcess = servesOnly ? {
|
|
3873
|
+
crons: [],
|
|
3874
|
+
queues: [],
|
|
3875
|
+
subscribers: []
|
|
3876
|
+
} : {
|
|
3877
|
+
crons: hostedCrons,
|
|
3878
|
+
queues: hostedQueues,
|
|
3879
|
+
subscribers: hostedSubscribers
|
|
3880
|
+
};
|
|
3881
|
+
const reach = derived.surface ? reachedBy(declared, [derived.surface.id, ...servesOnly ? [] : hosted.map((unit) => unit.id)], [
|
|
3882
|
+
...allEndpoints,
|
|
3883
|
+
...allFunctions,
|
|
3884
|
+
...inProcess.crons,
|
|
3885
|
+
...inProcess.queues,
|
|
3886
|
+
...inProcess.subscribers
|
|
3887
|
+
]) : declared;
|
|
3888
|
+
Object.assign(buildContext, runtimeDrivers({
|
|
3889
|
+
appRoot,
|
|
3890
|
+
reach,
|
|
3891
|
+
cacheBackend,
|
|
3892
|
+
eventsBackend
|
|
3893
|
+
}));
|
|
3845
3894
|
if (target === "server") buildContext.telemetry = require_EndpointGenerator.telemetryFor({
|
|
3846
|
-
node: derived.surface ?
|
|
3895
|
+
node: processTelemetry(declared, derived.surface?.id, servesOnly ? [] : hosted.map((unit) => unit.id)),
|
|
3847
3896
|
appRoot,
|
|
3848
3897
|
app: appNameOf(input),
|
|
3849
3898
|
cwd: workspaceRoot,
|
|
@@ -3861,40 +3910,37 @@ async function buildApp(input) {
|
|
|
3861
3910
|
logger$4.log("No endpoints, functions, crons, subscribers, queues, or topics found to process");
|
|
3862
3911
|
return {};
|
|
3863
3912
|
}
|
|
3864
|
-
if (
|
|
3865
|
-
|
|
3866
|
-
|
|
3867
|
-
|
|
3868
|
-
|
|
3869
|
-
|
|
3870
|
-
|
|
3871
|
-
|
|
3872
|
-
|
|
3873
|
-
].filter(([n]) => n > 0).map(([n, what]) => `${n} ${what}${n === 1 ? "" : "s"}`);
|
|
3874
|
-
if (left.length > 0) logger$4.log(`Serving ${derived.surface.id} only: leaving out ${left.join(", ")} — they run in a Worker's image`);
|
|
3875
|
-
}
|
|
3876
|
-
const result = await buildForTarget(target, buildContext, appRoot, workspaceRoot, endpointGenerator, functionGenerator, cronGenerator, subscriberGenerator, queueGenerator, topicGenerator, allEndpoints, allFunctions, allCrons, allSubscribers, allQueues, allTopics, enableOpenApi, input.skipBundle ?? false, input.stage);
|
|
3877
|
-
if (target === "server" && production?.enabled && input.workspace) {
|
|
3878
|
-
const appName = Object.entries(input.workspace.apps).find(([, app]) => (0, node_path.resolve)(input.workspace.root, app.path) === (0, node_path.resolve)(appRoot))?.[0];
|
|
3879
|
-
await buildWorkers({
|
|
3880
|
-
context: buildContext,
|
|
3881
|
-
telemetry: (workerId) => require_EndpointGenerator.telemetryFor({
|
|
3882
|
-
node: require_seeds.telemetryOf(declared, workerId),
|
|
3913
|
+
if (servesOnly && production) buildContext.production = {
|
|
3914
|
+
...production,
|
|
3915
|
+
subscribers: "exclude"
|
|
3916
|
+
};
|
|
3917
|
+
const result = await buildForTarget(target, buildContext, appRoot, workspaceRoot, endpointGenerator, functionGenerator, cronGenerator, subscriberGenerator, queueGenerator, topicGenerator, allEndpoints, allFunctions, inProcess.crons, inProcess.subscribers, inProcess.queues, allTopics, enableOpenApi, input.skipBundle ?? false, input.stage);
|
|
3918
|
+
if (target === "server" && production?.enabled) await buildWorkers({
|
|
3919
|
+
context: (workerId, work) => ({
|
|
3920
|
+
...buildContext,
|
|
3921
|
+
...runtimeDrivers({
|
|
3883
3922
|
appRoot,
|
|
3884
|
-
|
|
3885
|
-
|
|
3886
|
-
|
|
3887
|
-
|
|
3888
|
-
|
|
3889
|
-
|
|
3890
|
-
|
|
3891
|
-
|
|
3892
|
-
|
|
3893
|
-
|
|
3894
|
-
|
|
3895
|
-
...input.
|
|
3896
|
-
})
|
|
3897
|
-
|
|
3923
|
+
reach: reachedBy(declared, [workerId], work),
|
|
3924
|
+
cacheBackend,
|
|
3925
|
+
eventsBackend
|
|
3926
|
+
})
|
|
3927
|
+
}),
|
|
3928
|
+
telemetry: (workerId) => require_EndpointGenerator.telemetryFor({
|
|
3929
|
+
node: require_seeds.telemetryOf(declared, workerId),
|
|
3930
|
+
appRoot,
|
|
3931
|
+
app: appNameOf(input),
|
|
3932
|
+
cwd: workspaceRoot,
|
|
3933
|
+
serviceName: workerId,
|
|
3934
|
+
...input.workspaceName && { workspaceName: input.workspaceName }
|
|
3935
|
+
}),
|
|
3936
|
+
workers: hosted,
|
|
3937
|
+
serverDir: (0, node_path.join)(appRoot, ".gkm", "server"),
|
|
3938
|
+
crons: hostedCrons,
|
|
3939
|
+
queues: hostedQueues,
|
|
3940
|
+
subscribers: hostedSubscribers,
|
|
3941
|
+
bundle: Boolean(production.bundle && !input.skipBundle),
|
|
3942
|
+
...input.stage ? { stage: input.stage } : {}
|
|
3943
|
+
});
|
|
3898
3944
|
await require_openapi.generateOpenApi(allEndpoints.map(({ construct }) => construct), {
|
|
3899
3945
|
openapi: config.openapi,
|
|
3900
3946
|
root: workspaceRoot,
|
|
@@ -3908,7 +3954,35 @@ async function buildApp(input) {
|
|
|
3908
3954
|
});
|
|
3909
3955
|
return {
|
|
3910
3956
|
...result,
|
|
3911
|
-
...buildContext.databaseApi ? { databaseApi: buildContext.databaseApi.path } : {}
|
|
3957
|
+
...buildContext.databaseApi ? { databaseApi: buildContext.databaseApi.path } : {},
|
|
3958
|
+
...!servesOnly && hosted.length > 0 ? { workers: hosted.map((unit) => unit.id) } : {}
|
|
3959
|
+
};
|
|
3960
|
+
}
|
|
3961
|
+
/**
|
|
3962
|
+
* The `Telemetry` node a process emits through: its surface's, or — where it
|
|
3963
|
+
* runs a worker's work, under `gkm dev` — that worker's.
|
|
3964
|
+
*/
|
|
3965
|
+
function processTelemetry(declared, surfaceId, workers) {
|
|
3966
|
+
for (const id of [...surfaceId ? [surfaceId] : [], ...workers]) {
|
|
3967
|
+
const node = require_seeds.telemetryOf(declared, id);
|
|
3968
|
+
if (node) return node;
|
|
3969
|
+
}
|
|
3970
|
+
}
|
|
3971
|
+
/**
|
|
3972
|
+
* The drivers a process's entry registers, from the declarations it reaches:
|
|
3973
|
+
* the cache's — the declaration for one that named its database, the deploy
|
|
3974
|
+
* target's default for one that named nowhere — and the broker's, only when
|
|
3975
|
+
* it reaches a topic or a queue (see `eventsBackendsIn`).
|
|
3976
|
+
*/
|
|
3977
|
+
function runtimeDrivers(options) {
|
|
3978
|
+
const eventsBackends = require_drivers.eventsBackendsIn(options.reach, options.eventsBackend);
|
|
3979
|
+
return {
|
|
3980
|
+
storageDrivers: require_drivers.driversFor({
|
|
3981
|
+
appRoot: options.appRoot,
|
|
3982
|
+
cache: require_drivers.cacheBackendsIn(options.reach, options.cacheBackend),
|
|
3983
|
+
events: eventsBackends
|
|
3984
|
+
}),
|
|
3985
|
+
eventsBackends
|
|
3912
3986
|
};
|
|
3913
3987
|
}
|
|
3914
3988
|
/**
|
|
@@ -3923,8 +3997,13 @@ async function buildWorkers(input) {
|
|
|
3923
3997
|
const queues = owned(input.queues);
|
|
3924
3998
|
const subscribers = owned(input.subscribers);
|
|
3925
3999
|
const telemetry = input.telemetry(worker.id);
|
|
4000
|
+
const context = input.context(worker.id, [
|
|
4001
|
+
...crons,
|
|
4002
|
+
...queues,
|
|
4003
|
+
...subscribers
|
|
4004
|
+
]);
|
|
3926
4005
|
const entryPoint = await generator.build({
|
|
3927
|
-
context
|
|
4006
|
+
context,
|
|
3928
4007
|
workerId: worker.id,
|
|
3929
4008
|
...telemetry ? { telemetry } : {},
|
|
3930
4009
|
outputDir: require_seeds.workerEntryDir(input.serverDir, worker.id),
|
|
@@ -3934,15 +4013,15 @@ async function buildWorkers(input) {
|
|
|
3934
4013
|
});
|
|
3935
4014
|
logger$4.log(`Generated worker ${worker.id}: ${crons.length} crons, ${queues.length} queues, ${subscribers.length} subscribers`);
|
|
3936
4015
|
if (!input.bundle) continue;
|
|
3937
|
-
const { bundleServer } = await Promise.resolve().then(() => require("./bundler-
|
|
4016
|
+
const { bundleServer } = await Promise.resolve().then(() => require("./bundler-DBTA8gXs.cjs"));
|
|
3938
4017
|
const outfile = require_seeds.workerBundleName(worker.id);
|
|
3939
4018
|
await bundleServer({
|
|
3940
4019
|
entryPoint,
|
|
3941
4020
|
outputDir: (0, node_path.join)(input.serverDir, "dist"),
|
|
3942
4021
|
outfile,
|
|
3943
|
-
minify:
|
|
4022
|
+
minify: context.production?.minify ?? false,
|
|
3944
4023
|
sourcemap: false,
|
|
3945
|
-
external:
|
|
4024
|
+
external: context.production?.external ?? [],
|
|
3946
4025
|
...input.stage ? { stage: input.stage } : {},
|
|
3947
4026
|
constructs: [
|
|
3948
4027
|
...crons,
|
|
@@ -4020,7 +4099,7 @@ async function buildForTarget(target, context, appRoot, workspaceRoot, endpointG
|
|
|
4020
4099
|
let masterKey;
|
|
4021
4100
|
if (context.production?.bundle && !skipBundle) {
|
|
4022
4101
|
logger$4.log(`\n📦 Bundling production server...`);
|
|
4023
|
-
const { bundleServer } = await Promise.resolve().then(() => require("./bundler-
|
|
4102
|
+
const { bundleServer } = await Promise.resolve().then(() => require("./bundler-DBTA8gXs.cjs"));
|
|
4024
4103
|
const allConstructs = [
|
|
4025
4104
|
...endpoints.map((e) => e.construct),
|
|
4026
4105
|
...functions.map((f) => f.construct),
|
|
@@ -5848,25 +5927,25 @@ function loadPackageJson() {
|
|
|
5848
5927
|
* Run: pnpm --filter @geekmidas/cli sync-versions
|
|
5849
5928
|
*/
|
|
5850
5929
|
const GEEKMIDAS_VERSIONS = {
|
|
5851
|
-
"@geekmidas/audit": "~10.0.0-alpha.
|
|
5852
|
-
"@geekmidas/auth": "~10.0.0-alpha.
|
|
5853
|
-
"@geekmidas/cache": "~10.0.0-alpha.
|
|
5854
|
-
"@geekmidas/client": "~10.0.0-alpha.
|
|
5855
|
-
"@geekmidas/cloud": "~10.0.0-alpha.
|
|
5856
|
-
"@geekmidas/constructs": "~10.0.0-alpha.
|
|
5857
|
-
"@geekmidas/db": "~10.0.0-alpha.
|
|
5858
|
-
"@geekmidas/emailkit": "~10.0.0-alpha.
|
|
5859
|
-
"@geekmidas/envkit": "~10.0.0-alpha.
|
|
5860
|
-
"@geekmidas/errors": "~10.0.0-alpha.
|
|
5861
|
-
"@geekmidas/events": "~10.0.0-alpha.
|
|
5862
|
-
"@geekmidas/logger": "~10.0.0-alpha.
|
|
5863
|
-
"@geekmidas/manifest": "~10.0.0-alpha.
|
|
5864
|
-
"@geekmidas/rate-limit": "~10.0.0-alpha.
|
|
5865
|
-
"@geekmidas/schema": "~10.0.0-alpha.
|
|
5866
|
-
"@geekmidas/services": "~10.0.0-alpha.
|
|
5867
|
-
"@geekmidas/storage": "~10.0.0-alpha.
|
|
5868
|
-
"@geekmidas/telescope": "~10.0.0-alpha.
|
|
5869
|
-
"@geekmidas/testkit": "~10.0.0-alpha.
|
|
5930
|
+
"@geekmidas/audit": "~10.0.0-alpha.104",
|
|
5931
|
+
"@geekmidas/auth": "~10.0.0-alpha.104",
|
|
5932
|
+
"@geekmidas/cache": "~10.0.0-alpha.104",
|
|
5933
|
+
"@geekmidas/client": "~10.0.0-alpha.104",
|
|
5934
|
+
"@geekmidas/cloud": "~10.0.0-alpha.104",
|
|
5935
|
+
"@geekmidas/constructs": "~10.0.0-alpha.104",
|
|
5936
|
+
"@geekmidas/db": "~10.0.0-alpha.104",
|
|
5937
|
+
"@geekmidas/emailkit": "~10.0.0-alpha.104",
|
|
5938
|
+
"@geekmidas/envkit": "~10.0.0-alpha.104",
|
|
5939
|
+
"@geekmidas/errors": "~10.0.0-alpha.104",
|
|
5940
|
+
"@geekmidas/events": "~10.0.0-alpha.104",
|
|
5941
|
+
"@geekmidas/logger": "~10.0.0-alpha.104",
|
|
5942
|
+
"@geekmidas/manifest": "~10.0.0-alpha.104",
|
|
5943
|
+
"@geekmidas/rate-limit": "~10.0.0-alpha.104",
|
|
5944
|
+
"@geekmidas/schema": "~10.0.0-alpha.104",
|
|
5945
|
+
"@geekmidas/services": "~10.0.0-alpha.104",
|
|
5946
|
+
"@geekmidas/storage": "~10.0.0-alpha.104",
|
|
5947
|
+
"@geekmidas/telescope": "~10.0.0-alpha.104",
|
|
5948
|
+
"@geekmidas/testkit": "~10.0.0-alpha.104",
|
|
5870
5949
|
"@geekmidas/cli": `~${loadPackageJson().version}`
|
|
5871
5950
|
};
|
|
5872
5951
|
//#endregion
|
|
@@ -6267,7 +6346,7 @@ const COMMIT = /^[0-9a-f]{40}$/;
|
|
|
6267
6346
|
* The `uses:` value for the stages action, with a comment saying which CLI
|
|
6268
6347
|
* release the pinned commit is.
|
|
6269
6348
|
*/
|
|
6270
|
-
function stagesActionUses(commit = "
|
|
6349
|
+
function stagesActionUses(commit = "088aa26a6c82b4916af4faddd5755e030fb459d5", version = cliVersion()) {
|
|
6271
6350
|
return commit && COMMIT.test(commit) ? `${STAGES_ACTION}@${commit} # @geekmidas/cli ${version}` : `${STAGES_ACTION}@main # pin to a commit SHA: see the action's README`;
|
|
6272
6351
|
}
|
|
6273
6352
|
//#endregion
|
|
@@ -11904,6 +11983,7 @@ async function testCommand(options = {}) {
|
|
|
11904
11983
|
secretsFileName: "test-secrets.json",
|
|
11905
11984
|
reconcileStage: "test"
|
|
11906
11985
|
});
|
|
11986
|
+
const credentials = result.reconciled ? require_SubscriberGenerator.assertTestCredentials(result.secretsRoot, result.reconciled.plan, result.credentials) : {};
|
|
11907
11987
|
let finalCredentials = { ...result.credentials };
|
|
11908
11988
|
if (result.appInfo) {
|
|
11909
11989
|
const sniffed = await require_sniffer.sniffAppEnvironment(result.appInfo.app, result.appInfo.appName, result.appInfo.workspaceRoot, { logWarnings: false });
|
|
@@ -11911,7 +11991,10 @@ async function testCommand(options = {}) {
|
|
|
11911
11991
|
const needed = /* @__PURE__ */ new Set([...sniffed.requiredEnvVars, ...result.declaredKeys]);
|
|
11912
11992
|
const filtered = {};
|
|
11913
11993
|
for (const [key, value] of Object.entries(finalCredentials)) if (needed.has(key)) filtered[key] = value;
|
|
11914
|
-
finalCredentials =
|
|
11994
|
+
finalCredentials = {
|
|
11995
|
+
...filtered,
|
|
11996
|
+
...credentials
|
|
11997
|
+
};
|
|
11915
11998
|
console.log(` 🔍 Sniffed ${sniffed.requiredEnvVars.length} required env var(s)` + (result.declaredKeys.length > 0 ? `, kept ${result.declaredKeys.length} declared` : ""));
|
|
11916
11999
|
}
|
|
11917
12000
|
}
|
|
@@ -12005,8 +12088,8 @@ function testDatabases(reconciled) {
|
|
|
12005
12088
|
* starts without the reference data the app needs.
|
|
12006
12089
|
*/
|
|
12007
12090
|
async function migrateTestStage(workspace, env) {
|
|
12008
|
-
const { migrateAndSeed } = await Promise.resolve().then(() => require("./migrate-
|
|
12009
|
-
const { discover } = await Promise.resolve().then(() => require("./discover-
|
|
12091
|
+
const { migrateAndSeed } = await Promise.resolve().then(() => require("./migrate-DXVzuw-s.cjs"));
|
|
12092
|
+
const { discover } = await Promise.resolve().then(() => require("./discover-Bsr7HjqJ.cjs")).then((n) => n.discover_exports);
|
|
12010
12093
|
const sources = {};
|
|
12011
12094
|
const manifest = await discover({
|
|
12012
12095
|
patterns: require_seeds.constructGlobs(workspace),
|
|
@@ -12441,7 +12524,7 @@ program.command("migrate").description("Apply each database construct's migratio
|
|
|
12441
12524
|
try {
|
|
12442
12525
|
const globalOptions = program.opts();
|
|
12443
12526
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12444
|
-
const { migrateCommand } = await Promise.resolve().then(() => require("./migrate-
|
|
12527
|
+
const { migrateCommand } = await Promise.resolve().then(() => require("./migrate-DXVzuw-s.cjs"));
|
|
12445
12528
|
await migrateCommand({
|
|
12446
12529
|
...options,
|
|
12447
12530
|
...construct ? { construct } : {}
|
|
@@ -12454,7 +12537,7 @@ program.command("seed").description("Migrate, then run each database construct's
|
|
|
12454
12537
|
try {
|
|
12455
12538
|
const globalOptions = program.opts();
|
|
12456
12539
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12457
|
-
const { seedCommand } = await Promise.resolve().then(() => require("./migrate-
|
|
12540
|
+
const { seedCommand } = await Promise.resolve().then(() => require("./migrate-DXVzuw-s.cjs"));
|
|
12458
12541
|
await seedCommand({
|
|
12459
12542
|
...options,
|
|
12460
12543
|
...construct ? { construct } : {}
|
|
@@ -12467,7 +12550,7 @@ program.command("migration").description("Write a construct's next migration: an
|
|
|
12467
12550
|
try {
|
|
12468
12551
|
const globalOptions = program.opts();
|
|
12469
12552
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12470
|
-
const { migrationCommand } = await Promise.resolve().then(() => require("./migrate-
|
|
12553
|
+
const { migrationCommand } = await Promise.resolve().then(() => require("./migrate-DXVzuw-s.cjs"));
|
|
12471
12554
|
await migrationCommand({
|
|
12472
12555
|
construct,
|
|
12473
12556
|
...name ? { name } : {}
|
|
@@ -12567,7 +12650,7 @@ program.command("secrets:add").description("Build the keys a stage must be given
|
|
|
12567
12650
|
try {
|
|
12568
12651
|
const globalOptions = program.opts();
|
|
12569
12652
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12570
|
-
const { secretsAddCommand } = await Promise.resolve().then(() => require("./add-
|
|
12653
|
+
const { secretsAddCommand } = await Promise.resolve().then(() => require("./add-C_lp7-oD.cjs"));
|
|
12571
12654
|
await secretsAddCommand(options);
|
|
12572
12655
|
} catch (error) {
|
|
12573
12656
|
exitWithError(error);
|
|
@@ -12577,7 +12660,7 @@ program.command("encryption:rotate").description("Add a new current key to an En
|
|
|
12577
12660
|
try {
|
|
12578
12661
|
const globalOptions = program.opts();
|
|
12579
12662
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12580
|
-
const { encryptionRotateCommand } = await Promise.resolve().then(() => require("./encryption-
|
|
12663
|
+
const { encryptionRotateCommand } = await Promise.resolve().then(() => require("./encryption-2KOlWvfq.cjs"));
|
|
12581
12664
|
await encryptionRotateCommand(construct, options);
|
|
12582
12665
|
} catch (error) {
|
|
12583
12666
|
exitWithError(error);
|
|
@@ -12587,7 +12670,7 @@ program.command("encryption:retire").description("Remove an old key from an Encr
|
|
|
12587
12670
|
try {
|
|
12588
12671
|
const globalOptions = program.opts();
|
|
12589
12672
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12590
|
-
const { encryptionRetireCommand } = await Promise.resolve().then(() => require("./encryption-
|
|
12673
|
+
const { encryptionRetireCommand } = await Promise.resolve().then(() => require("./encryption-2KOlWvfq.cjs"));
|
|
12591
12674
|
await encryptionRetireCommand(construct, key, options);
|
|
12592
12675
|
} catch (error) {
|
|
12593
12676
|
exitWithError(error);
|
|
@@ -12626,7 +12709,7 @@ program.command("secrets:reconcile").description("Backfill missing custom secret
|
|
|
12626
12709
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12627
12710
|
const { loadWorkspaceConfig } = await Promise.resolve().then(() => require("./config.cjs"));
|
|
12628
12711
|
const { reconcileMissingSecrets } = await Promise.resolve().then(() => require("./reconcile-CuCQBa5-.cjs"));
|
|
12629
|
-
const { secretsStoreFor } = await Promise.resolve().then(() => require("./seeds-
|
|
12712
|
+
const { secretsStoreFor } = await Promise.resolve().then(() => require("./seeds-CjBwLvWY.cjs")).then((n) => n.store_exports);
|
|
12630
12713
|
const { workspace } = await loadWorkspaceConfig();
|
|
12631
12714
|
const stage = options.stage ?? workspace.stages.local;
|
|
12632
12715
|
const store = await secretsStoreFor(workspace, stage);
|
|
@@ -12635,7 +12718,7 @@ program.command("secrets:reconcile").description("Backfill missing custom secret
|
|
|
12635
12718
|
console.error(`No secrets found for stage "${stage}". Run "gkm secrets:init --stage ${stage}" first.`);
|
|
12636
12719
|
process.exit(1);
|
|
12637
12720
|
}
|
|
12638
|
-
const { derivedContainers } = await Promise.resolve().then(() => require("./seeds-
|
|
12721
|
+
const { derivedContainers } = await Promise.resolve().then(() => require("./seeds-CjBwLvWY.cjs")).then((n) => n.workspace_exports);
|
|
12639
12722
|
const result = reconcileMissingSecrets(secrets, workspace, await derivedContainers(workspace, stage));
|
|
12640
12723
|
if (!result) {
|
|
12641
12724
|
console.log(`\n✓ Secrets for stage "${stage}" are up-to-date`);
|
|
@@ -12652,14 +12735,14 @@ program.command("secrets:migrate").description("Copy a deployed stage's secrets
|
|
|
12652
12735
|
try {
|
|
12653
12736
|
const globalOptions = program.opts();
|
|
12654
12737
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12655
|
-
const { secretsMigrateCommand } = await Promise.resolve().then(() => require("./migrate-
|
|
12738
|
+
const { secretsMigrateCommand } = await Promise.resolve().then(() => require("./migrate-BQfq48xK.cjs"));
|
|
12656
12739
|
await secretsMigrateCommand(options);
|
|
12657
12740
|
} catch (error) {
|
|
12658
12741
|
exitWithError(error);
|
|
12659
12742
|
}
|
|
12660
12743
|
});
|
|
12661
12744
|
program.command("deploy").description("Deploy a stage through its target").option("--target <name>", "Deploy target: dokploy, compose, sst, or one named in deploy.targets (default: deploy.default)").option("--provider <provider>", "[DEPRECATED] Use --target instead").requiredOption("--stage <stage>", "Deployment stage (e.g., production, staging)").option("--tag <tag>", "Image tag (default: stage-timestamp; compose: the commit). Compose pulls a given tag").option("--skip-push", "Skip pushing image to registry").option("--skip-build", "Skip build step (use existing build)").option("--json", "Write events as JSON lines instead of progress; never prompts").option("--dry-run", "Show what would be created or reused; change, build and push nothing").option("--atomic", "If the release fails, roll back every app it released, not only the failed ones").option("--allow-dev-services", "Server targets: run the dev service (MinIO, Mailpit) for every bucket and mail the stage doesn't account for. Not production-grade").option("--skip-dns", "Compose: neither write the public hosts' DNS records nor check they point at GKM_SERVER_IPV4 (a CDN or proxy in front, or records written elsewhere)").option("--rotate-keys", "Deployed stage: each provider issues its runtime keys a successor (the old one is deleted by the next deploy)").option("--retire-old-keys", "Deployed stage: delete a rotated-out key now instead of on the next deploy").action(async (options) => {
|
|
12662
|
-
const { deployCli } = await Promise.resolve().then(() => require("./cli-
|
|
12745
|
+
const { deployCli } = await Promise.resolve().then(() => require("./cli-D7FyFbeC.cjs"));
|
|
12663
12746
|
const globalOptions = program.opts();
|
|
12664
12747
|
const code = await deployCli({
|
|
12665
12748
|
cwd: (0, node_path.resolve)(globalOptions.cwd ?? process.cwd()),
|
|
@@ -12679,8 +12762,8 @@ program.command("deploy").description("Deploy a stage through its target").optio
|
|
|
12679
12762
|
});
|
|
12680
12763
|
program.command("deploy:rollback").description("Put a stage's app back on its previous release (Dokploy): one app with --app, every app with --atomic").requiredOption("--stage <stage>", "A deployed stage").option("--app <app>", "The app to roll back").option("--atomic", "Roll back every app that has an earlier release").action(async (options) => {
|
|
12681
12764
|
try {
|
|
12682
|
-
const { rollbackStage } = await Promise.resolve().then(() => require("./rollback-
|
|
12683
|
-
const { terminalCredentials } = await Promise.resolve().then(() => require("./terminal-
|
|
12765
|
+
const { rollbackStage } = await Promise.resolve().then(() => require("./rollback-dkinZaOv.cjs")).then((n) => n.rollback_exports);
|
|
12766
|
+
const { terminalCredentials } = await Promise.resolve().then(() => require("./terminal-D_NRPW4W.cjs"));
|
|
12684
12767
|
const globalOptions = program.opts();
|
|
12685
12768
|
await rollbackStage({
|
|
12686
12769
|
cwd: (0, node_path.resolve)(globalOptions.cwd ?? process.cwd()),
|
|
@@ -12713,7 +12796,7 @@ program.command("deploy:github").description("Let GitHub Actions deploy a stage:
|
|
|
12713
12796
|
try {
|
|
12714
12797
|
const globalOptions = program.opts();
|
|
12715
12798
|
if (globalOptions.cwd) process.chdir(globalOptions.cwd);
|
|
12716
|
-
const { deployGithubCommand } = await Promise.resolve().then(() => require("./github-
|
|
12799
|
+
const { deployGithubCommand } = await Promise.resolve().then(() => require("./github-BM6afosB.cjs"));
|
|
12717
12800
|
await deployGithubCommand(options);
|
|
12718
12801
|
} catch (error) {
|
|
12719
12802
|
exitWithError(error);
|