@geekmidas/cli 10.0.0-alpha.68 → 10.0.0-alpha.70

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.
Files changed (174) hide show
  1. package/dist/{LegacyStateStore-BZiO9-Lw.cjs → LegacyStateStore-Dd5IwiyC.cjs} +2 -2
  2. package/dist/{LegacyStateStore-BZiO9-Lw.cjs.map → LegacyStateStore-Dd5IwiyC.cjs.map} +1 -1
  3. package/dist/{LegacyStateStore-C39UKwmf.mjs → LegacyStateStore-NSHEinQi.mjs} +2 -2
  4. package/dist/{LegacyStateStore-C39UKwmf.mjs.map → LegacyStateStore-NSHEinQi.mjs.map} +1 -1
  5. package/dist/{LocalStateStore-DHVsZLyF.cjs → LocalStateStore-DTylG4T4.cjs} +2 -2
  6. package/dist/{LocalStateStore-DHVsZLyF.cjs.map → LocalStateStore-DTylG4T4.cjs.map} +1 -1
  7. package/dist/{LocalStateStore-Dk3Wbvzk.mjs → LocalStateStore-DUoG2wA_.mjs} +2 -2
  8. package/dist/{LocalStateStore-Dk3Wbvzk.mjs.map → LocalStateStore-DUoG2wA_.mjs.map} +1 -1
  9. package/dist/{OpenApiTsGenerator-BmUAcR7d.mjs → OpenApiTsGenerator-BYD9EcJi.mjs} +44 -13
  10. package/dist/OpenApiTsGenerator-BYD9EcJi.mjs.map +1 -0
  11. package/dist/{OpenApiTsGenerator-B2zrdyP4.cjs → OpenApiTsGenerator-CpRWM0N6.cjs} +44 -13
  12. package/dist/OpenApiTsGenerator-CpRWM0N6.cjs.map +1 -0
  13. package/dist/{S3StateStore--4tYVMAL.cjs → S3StateStore-D7hrU-sy.cjs} +2 -2
  14. package/dist/{S3StateStore--4tYVMAL.cjs.map → S3StateStore-D7hrU-sy.cjs.map} +1 -1
  15. package/dist/{S3StateStore-B_ZF9eHt.mjs → S3StateStore-Dxob3PNA.mjs} +2 -2
  16. package/dist/{S3StateStore-B_ZF9eHt.mjs.map → S3StateStore-Dxob3PNA.mjs.map} +1 -1
  17. package/dist/{SSMStateStore-ACZ8hRvZ.cjs → SSMStateStore-DGIKJ4NN.cjs} +2 -2
  18. package/dist/{SSMStateStore-ACZ8hRvZ.cjs.map → SSMStateStore-DGIKJ4NN.cjs.map} +1 -1
  19. package/dist/{SSMStateStore-DjPuKqrm.mjs → SSMStateStore-Dvl4A8Up.mjs} +2 -2
  20. package/dist/{SSMStateStore-DjPuKqrm.mjs.map → SSMStateStore-Dvl4A8Up.mjs.map} +1 -1
  21. package/dist/add-BuviRszv.mjs +566 -0
  22. package/dist/add-BuviRszv.mjs.map +1 -0
  23. package/dist/add-DHIk61nK.cjs +568 -0
  24. package/dist/add-DHIk61nK.cjs.map +1 -0
  25. package/dist/{bundler-C1pnNrR0.cjs → bundler-D7dcJVgj.cjs} +5 -5
  26. package/dist/{bundler-C1pnNrR0.cjs.map → bundler-D7dcJVgj.cjs.map} +1 -1
  27. package/dist/{bundler-C-w7aGoZ.mjs → bundler-DJlsYzm7.mjs} +5 -5
  28. package/dist/{bundler-C-w7aGoZ.mjs.map → bundler-DJlsYzm7.mjs.map} +1 -1
  29. package/dist/{cli-BLyD4c0O.cjs → cli-7zCum6uN.cjs} +4 -4
  30. package/dist/{cli-BLyD4c0O.cjs.map → cli-7zCum6uN.cjs.map} +1 -1
  31. package/dist/{cli-Ce4pLL5O.mjs → cli-BjnqVnE6.mjs} +4 -4
  32. package/dist/{cli-Ce4pLL5O.mjs.map → cli-BjnqVnE6.mjs.map} +1 -1
  33. package/dist/{compose-DvsgumY2.cjs → compose-BJYHmuvx.cjs} +368 -25
  34. package/dist/compose-BJYHmuvx.cjs.map +1 -0
  35. package/dist/{compose-DFxuYhn6.mjs → compose-CByVaaeR.mjs} +363 -26
  36. package/dist/compose-CByVaaeR.mjs.map +1 -0
  37. package/dist/{config-CxEp_g7j.d.mts → config-BN6iXvyR.d.mts} +3 -3
  38. package/dist/{config-BnA0kPTY.d.cts.map → config-BN6iXvyR.d.mts.map} +1 -1
  39. package/dist/{config-BnA0kPTY.d.cts → config-j9zBKaEG.d.cts} +3 -3
  40. package/dist/{config-CxEp_g7j.d.mts.map → config-j9zBKaEG.d.cts.map} +1 -1
  41. package/dist/config.cjs +3 -3
  42. package/dist/config.d.cts +3 -3
  43. package/dist/config.d.mts +3 -3
  44. package/dist/config.mjs +3 -3
  45. package/dist/credentialSchemas-BcNL1N5R.cjs +271 -0
  46. package/dist/credentialSchemas-BcNL1N5R.cjs.map +1 -0
  47. package/dist/credentialSchemas-BmYxnEz_.mjs +236 -0
  48. package/dist/credentialSchemas-BmYxnEz_.mjs.map +1 -0
  49. package/dist/deploy/public.cjs +7 -7
  50. package/dist/deploy/public.d.cts +3 -3
  51. package/dist/deploy/public.d.cts.map +1 -1
  52. package/dist/deploy/public.d.mts +3 -3
  53. package/dist/deploy/public.d.mts.map +1 -1
  54. package/dist/deploy/public.mjs +7 -7
  55. package/dist/{deploy-C08GONYW.cjs → deploy--ZU9gOOa.cjs} +6 -6
  56. package/dist/{deploy-C08GONYW.cjs.map → deploy--ZU9gOOa.cjs.map} +1 -1
  57. package/dist/{deploy-D-EVOWvu.mjs → deploy-CCSGr7be.mjs} +6 -6
  58. package/dist/{deploy-D-EVOWvu.mjs.map → deploy-CCSGr7be.mjs.map} +1 -1
  59. package/dist/{discover-OEfZ9OkA.cjs → discover-B4VjaFJk.cjs} +2 -2
  60. package/dist/{discover-OEfZ9OkA.cjs.map → discover-B4VjaFJk.cjs.map} +1 -1
  61. package/dist/{discover-BFoJWKGD.mjs → discover-Buwf1z4P.mjs} +2 -2
  62. package/dist/{discover-BFoJWKGD.mjs.map → discover-Buwf1z4P.mjs.map} +1 -1
  63. package/dist/{dokploy-CZ6nfSV9.cjs → dokploy-BOupc9PK.cjs} +2 -2
  64. package/dist/{dokploy-CZ6nfSV9.cjs.map → dokploy-BOupc9PK.cjs.map} +1 -1
  65. package/dist/{dokploy-DU-XJsoT.mjs → dokploy-Bskfn1g5.mjs} +2 -2
  66. package/dist/{dokploy-DU-XJsoT.mjs.map → dokploy-Bskfn1g5.mjs.map} +1 -1
  67. package/dist/{encryption-CCcBSLZs.cjs → encryption-D-VkoJG4.cjs} +3 -3
  68. package/dist/{encryption-CCcBSLZs.cjs.map → encryption-D-VkoJG4.cjs.map} +1 -1
  69. package/dist/{encryption-DSiLau1-.mjs → encryption-DR-py9GX.mjs} +3 -3
  70. package/dist/{encryption-DSiLau1-.mjs.map → encryption-DR-py9GX.mjs.map} +1 -1
  71. package/dist/{engine-BM9Dy_DT.cjs → engine-Da8dBxt5.cjs} +16 -7
  72. package/dist/engine-Da8dBxt5.cjs.map +1 -0
  73. package/dist/{engine-llWnMZH5.mjs → engine-Xbv8NNdX.mjs} +16 -7
  74. package/dist/{engine-llWnMZH5.mjs.map → engine-Xbv8NNdX.mjs.map} +1 -1
  75. package/dist/{github-yy6WpHIl.mjs → github-D2pYzY7L.mjs} +3 -3
  76. package/dist/{github-yy6WpHIl.mjs.map → github-D2pYzY7L.mjs.map} +1 -1
  77. package/dist/{github-ZoMam0OH.cjs → github-DeXzs11c.cjs} +3 -3
  78. package/dist/{github-ZoMam0OH.cjs.map → github-DeXzs11c.cjs.map} +1 -1
  79. package/dist/{index-EvZBkycu.d.cts → index-Bk3NY6DN.d.cts} +2 -2
  80. package/dist/{index-CkX89m6S.d.mts.map → index-Bk3NY6DN.d.cts.map} +1 -1
  81. package/dist/{index-CkX89m6S.d.mts → index-DvoxuTqR.d.mts} +2 -2
  82. package/dist/{index-EvZBkycu.d.cts.map → index-DvoxuTqR.d.mts.map} +1 -1
  83. package/dist/index.cjs +89 -48
  84. package/dist/index.cjs.map +1 -1
  85. package/dist/index.mjs +89 -48
  86. package/dist/index.mjs.map +1 -1
  87. package/dist/{migrate-tOwxQBTI.cjs → migrate-BURDS8vy.cjs} +4 -4
  88. package/dist/{migrate-tOwxQBTI.cjs.map → migrate-BURDS8vy.cjs.map} +1 -1
  89. package/dist/{migrate-BWPuwiXk.mjs → migrate-DiJT84g9.mjs} +4 -4
  90. package/dist/{migrate-BWPuwiXk.mjs.map → migrate-DiJT84g9.mjs.map} +1 -1
  91. package/dist/openapi.cjs +1 -1
  92. package/dist/openapi.d.cts +1 -1
  93. package/dist/openapi.d.mts +1 -1
  94. package/dist/openapi.mjs +1 -1
  95. package/dist/{ready-B6uHr4sm.cjs → ready-C-qNcux-.cjs} +3 -3
  96. package/dist/{ready-B6uHr4sm.cjs.map → ready-C-qNcux-.cjs.map} +1 -1
  97. package/dist/{ready-2s3-CndS.mjs → ready-CfIiMts4.mjs} +3 -3
  98. package/dist/{ready-2s3-CndS.mjs.map → ready-CfIiMts4.mjs.map} +1 -1
  99. package/dist/reconcile/public.cjs +1 -1
  100. package/dist/reconcile/public.d.cts +1 -1
  101. package/dist/reconcile/public.d.mts +1 -1
  102. package/dist/reconcile/public.mjs +1 -1
  103. package/dist/{resolve-BymzGtuT.cjs → resolve-B7jJQmTo.cjs} +3 -3
  104. package/dist/{resolve-BymzGtuT.cjs.map → resolve-B7jJQmTo.cjs.map} +1 -1
  105. package/dist/{resolve-pIvXlZ1h.mjs → resolve-Dj5TQKoD.mjs} +3 -3
  106. package/dist/{resolve-pIvXlZ1h.mjs.map → resolve-Dj5TQKoD.mjs.map} +1 -1
  107. package/dist/{rollback-ZlsbQOvj.mjs → rollback-Bw9kESjz.mjs} +5 -5
  108. package/dist/{rollback-ZlsbQOvj.mjs.map → rollback-Bw9kESjz.mjs.map} +1 -1
  109. package/dist/{rollback-zdfi6Reg.cjs → rollback-DNK1HEHY.cjs} +5 -5
  110. package/dist/{rollback-zdfi6Reg.cjs.map → rollback-DNK1HEHY.cjs.map} +1 -1
  111. package/dist/{runtime-DWThEP-r.d.cts → runtime-CYAO4iZG.d.cts} +2 -2
  112. package/dist/{runtime-B3jNgeP-.d.mts.map → runtime-CYAO4iZG.d.cts.map} +1 -1
  113. package/dist/{runtime-B3jNgeP-.d.mts → runtime-DHJhe4QI.d.mts} +2 -2
  114. package/dist/{runtime-DWThEP-r.d.cts.map → runtime-DHJhe4QI.d.mts.map} +1 -1
  115. package/dist/sandbox/credentials-worker.cjs +54 -0
  116. package/dist/sandbox/credentials-worker.cjs.map +1 -0
  117. package/dist/sandbox/credentials-worker.d.cts +1 -0
  118. package/dist/sandbox/credentials-worker.d.mts +1 -0
  119. package/dist/sandbox/credentials-worker.mjs +55 -0
  120. package/dist/sandbox/credentials-worker.mjs.map +1 -0
  121. package/dist/sandbox/discover-worker.cjs +1 -1
  122. package/dist/sandbox/discover-worker.mjs +1 -1
  123. package/dist/sandbox/migrate-worker.cjs +1 -1
  124. package/dist/sandbox/migrate-worker.mjs +1 -1
  125. package/dist/{schemas-RUlKHu27.cjs → schemas-BObwxB_t.cjs} +164 -3
  126. package/dist/schemas-BObwxB_t.cjs.map +1 -0
  127. package/dist/{schemas-Cfhtpdo0.mjs → schemas-D-xeKJDD.mjs} +153 -4
  128. package/dist/schemas-D-xeKJDD.mjs.map +1 -0
  129. package/dist/{sniffer-D66HIvi9.cjs → sniffer-DpHpFZBD.cjs} +7 -7
  130. package/dist/sniffer-DpHpFZBD.cjs.map +1 -0
  131. package/dist/{sniffer-BdFeLSmA.mjs → sniffer-vAXsU_4G.mjs} +7 -7
  132. package/dist/sniffer-vAXsU_4G.mjs.map +1 -0
  133. package/dist/{state-Bn5JDMFT.mjs → state-527OmqvN.mjs} +156 -64
  134. package/dist/state-527OmqvN.mjs.map +1 -0
  135. package/dist/{state-CHZqCDRC.cjs → state-nS6I6s4u.cjs} +179 -63
  136. package/dist/state-nS6I6s4u.cjs.map +1 -0
  137. package/dist/target/public.cjs +1 -1
  138. package/dist/target/public.d.cts +2 -2
  139. package/dist/target/public.d.mts +2 -2
  140. package/dist/target/public.mjs +1 -1
  141. package/dist/{terminal-C3cv-OQu.mjs → terminal-C6TBo_SA.mjs} +2 -2
  142. package/dist/{terminal-C3cv-OQu.mjs.map → terminal-C6TBo_SA.mjs.map} +1 -1
  143. package/dist/{terminal-DjzgLu6m.cjs → terminal-CFO3xWoF.cjs} +2 -2
  144. package/dist/{terminal-DjzgLu6m.cjs.map → terminal-CFO3xWoF.cjs.map} +1 -1
  145. package/dist/{types-CZdCxUCK.d.cts → types-BD1jgA85.d.cts} +70 -2
  146. package/dist/types-BD1jgA85.d.cts.map +1 -0
  147. package/dist/{types-Da0E3Qv7.d.mts → types-DkG5WW8l.d.mts} +70 -2
  148. package/dist/types-DkG5WW8l.d.mts.map +1 -0
  149. package/dist/vitest.cjs +1 -1
  150. package/dist/vitest.mjs +1 -1
  151. package/dist/workspace/index.cjs +1 -1
  152. package/dist/workspace/index.d.cts +3 -3
  153. package/dist/workspace/index.d.mts +3 -3
  154. package/dist/workspace/index.mjs +1 -1
  155. package/dist/{workspace-Be6uBhlF.mjs → workspace-C7NqCsQF.mjs} +105 -3
  156. package/dist/workspace-C7NqCsQF.mjs.map +1 -0
  157. package/dist/{workspace-ON-bqiJz.cjs → workspace-vdrcRI-m.cjs} +116 -2
  158. package/dist/workspace-vdrcRI-m.cjs.map +1 -0
  159. package/package.json +16 -13
  160. package/dist/OpenApiTsGenerator-B2zrdyP4.cjs.map +0 -1
  161. package/dist/OpenApiTsGenerator-BmUAcR7d.mjs.map +0 -1
  162. package/dist/compose-DFxuYhn6.mjs.map +0 -1
  163. package/dist/compose-DvsgumY2.cjs.map +0 -1
  164. package/dist/engine-BM9Dy_DT.cjs.map +0 -1
  165. package/dist/schemas-Cfhtpdo0.mjs.map +0 -1
  166. package/dist/schemas-RUlKHu27.cjs.map +0 -1
  167. package/dist/sniffer-BdFeLSmA.mjs.map +0 -1
  168. package/dist/sniffer-D66HIvi9.cjs.map +0 -1
  169. package/dist/state-Bn5JDMFT.mjs.map +0 -1
  170. package/dist/state-CHZqCDRC.cjs.map +0 -1
  171. package/dist/types-CZdCxUCK.d.cts.map +0 -1
  172. package/dist/types-Da0E3Qv7.d.mts.map +0 -1
  173. package/dist/workspace-Be6uBhlF.mjs.map +0 -1
  174. package/dist/workspace-ON-bqiJz.cjs.map +0 -1
package/dist/index.mjs CHANGED
@@ -2,20 +2,21 @@
2
2
  import { n as __require, t as __exportAll } from "./rolldown-runtime-BhDjJH2R.mjs";
3
3
  import { r as DEFAULT_TIMEOUT_MS, t as CommandFailed } from "./run-BJLIerMM.mjs";
4
4
  import { c as getDokployCredentials, f as removeDokployCredentials, i as LocalSandbox, l as getDokployRegistryId, m as storeHostingerToken, p as storeDokployCredentials, s as getCredentialsPath, u as getDokployToken } from "./credentials-pAtB70k3.mjs";
5
- import { l as withOwningTsconfigJsx, r as discover, u as ConstructGenerator } from "./discover-BFoJWKGD.mjs";
5
+ import { l as withOwningTsconfigJsx, r as discover, u as ConstructGenerator } from "./discover-Buwf1z4P.mjs";
6
6
  import { t as appKey } from "./derive-B4vDpzgP.mjs";
7
- import { A as deployedProblems, D as InvalidStages, O as TEST_STAGE, c as getAppGkmConfig, j as stageProblems, n as allConstructGlobs, s as getAppBuildOrder } from "./workspace-Be6uBhlF.mjs";
7
+ import { A as deployedProblems, D as InvalidStages, O as TEST_STAGE, c as getAppGkmConfig, j as stageProblems, n as allConstructGlobs, s as getAppBuildOrder } from "./workspace-C7NqCsQF.mjs";
8
8
  import { ConfigNotFound, NotABackendApp, NotInAnApp, loadAppConfig, loadConfig, loadWorkspaceConfig, loadWorkspaceSettings, parseModuleConfig } from "./config.mjs";
9
- import { $ as quoteIdentifier, At as prepareEntryCredentials, B as backendsOf$1, Bt as deployIdentity, Ct as primaryPortKey, Dt as isPortAvailable, Et as findAvailablePort, Ft as getKeyPath, G as LOCAL_CA_PATH, H as derivedContainers, Jt as maskPassword, K as forgetState, Lt as projectKey, Mt as secretsStoreFor, Ot as loadEnvFiles, P as parseDevServices, Pt as FileSecretsStore, R as keyFingerprint, Tt as createEntryWrapper, U as reconcileWorkspace, V as constructGlobs, Xt as toEmbeddableSecrets, Z as postgresDatabaseNames, Zt as withCustomSecret, _t as providerOf, bt as describeServices, ht as cacheBackendFor, kt as loadSecretsForApp, nt as pgClient, wt as createCredentialsPreload, xt as fakeKey, y as dockerCommand, z as FAKE_ENV } from "./state-Bn5JDMFT.mjs";
10
- import { i as telemetryFor, n as EndpointGenerator, r as runtimeFor } from "./OpenApiTsGenerator-BmUAcR7d.mjs";
11
- import { g as createStateStore, n as sniffAppEnvironment, o as DokployApi } from "./sniffer-BdFeLSmA.mjs";
9
+ import { At as findAvailablePort, Dt as primaryPortKey, G as constructGlobs, H as keyFingerprint, I as parseDevServices, It as secretsStoreFor, K as derivedContainers, Mt as loadEnvFiles, Nt as loadSecretsForApp, Ot as createCredentialsPreload, Pt as prepareEntryCredentials, Qt as maskPassword, Rt as FileSecretsStore, Tt as fakeKey, U as FAKE_ENV, Vt as projectKey, W as backendsOf$1, Wt as deployIdentity, X as forgetState, Y as LOCAL_CA_PATH, en as toEmbeddableSecrets, jt as isPortAvailable, kt as createEntryWrapper, ot as pgClient, q as reconcileWorkspace, rt as quoteIdentifier, tn as withCustomSecret, tt as postgresDatabaseNames, wt as describeServices, xt as providerOf, y as dockerCommand, yt as cacheBackendFor, zt as getKeyPath } from "./state-527OmqvN.mjs";
10
+ import { i as telemetryFor, n as EndpointGenerator, r as runtimeFor } from "./OpenApiTsGenerator-BYD9EcJi.mjs";
11
+ import { g as createStateStore, n as sniffAppEnvironment, o as DokployApi } from "./sniffer-vAXsU_4G.mjs";
12
12
  import { generateOpenApi, openapiCommand, resolveOpenApiConfig } from "./openapi.mjs";
13
13
  import { a as describeHolder, i as assignAppPorts, o as holderOf, r as appTag, s as withAppPorts, t as APP_TAG_ENV } from "./appPorts-C9z9Pzn9.mjs";
14
- import { a as writeTestHarness, c as driversFor, i as TEST_MANIFEST_ENV, n as TEST_READY_FILE, o as SubscriberGenerator, s as cacheBackendsIn, t as TEST_READY_ENV } from "./ready-2s3-CndS.mjs";
14
+ import { a as writeTestHarness, c as driversFor, i as TEST_MANIFEST_ENV, n as TEST_READY_FILE, o as SubscriberGenerator, s as cacheBackendsIn, t as TEST_READY_ENV } from "./ready-CfIiMts4.mjs";
15
15
  import { n as withCompute, r as withRoutes, t as manifestModule } from "./emit-C1e8qD08.mjs";
16
- import { t as deploy$1 } from "./deploy-D-EVOWvu.mjs";
17
- import { a as dockerCompose, i as stackDir, r as composeProject, t as composeTarget } from "./compose-DFxuYhn6.mjs";
18
- import { t as LocalStateStore } from "./LocalStateStore-Dk3Wbvzk.mjs";
16
+ import { t as deploy$1 } from "./deploy-CCSGr7be.mjs";
17
+ import { a as stackDir, i as composeProject, o as dockerCompose, r as stackOverrideFile, t as composeTarget } from "./compose-CByVaaeR.mjs";
18
+ import { o as loadCredentialSchemas, t as CredentialsInvalid } from "./credentialSchemas-BmYxnEz_.mjs";
19
+ import { t as LocalStateStore } from "./LocalStateStore-DUoG2wA_.mjs";
19
20
  import { a as getExecCommand, c as validateProjectName, i as findWorkspaceRoot, n as detectPackageManager$1, o as getInstallCommand, r as findWorkspacePackages, s as getRunCommand, t as checkDirectoryExists } from "./utils-D_fxUqvU.mjs";
20
21
  import { createRequire } from "node:module";
21
22
  import { basename, dirname, isAbsolute, join, relative, resolve } from "node:path";
@@ -29,9 +30,9 @@ import { promisify } from "node:util";
29
30
  import { canonicalId, kebabCase, migrationFolder, provideKey, schemeBase, serviceKey } from "@geekmidas/manifest";
30
31
  import fg from "fast-glob";
31
32
  import { pathToFileURL } from "node:url";
33
+ import { connect } from "node:net";
32
34
  import { execFile, execSync, spawn } from "node:child_process";
33
35
  import chokidar from "chokidar";
34
- import { connect } from "node:net";
35
36
  import { createHash, randomBytes, timingSafeEqual } from "node:crypto";
36
37
  import { parseDocument } from "yaml";
37
38
  import prompts from "prompts";
@@ -46,7 +47,7 @@ import { Function } from "@geekmidas/constructs/functions";
46
47
  import { Queue } from "@geekmidas/constructs/queue";
47
48
  import { Topic } from "@geekmidas/constructs/topic";
48
49
  //#region package.json
49
- var version = "10.0.0-alpha.68";
50
+ var version = "10.0.0-alpha.70";
50
51
  //#endregion
51
52
  //#region src/prompt.ts
52
53
  /**
@@ -129,7 +130,7 @@ const logger$8 = console;
129
130
  * Validate Dokploy token by making a test API call
130
131
  */
131
132
  async function validateDokployToken(endpoint, token) {
132
- const { DokployApi } = await import("./sniffer-BdFeLSmA.mjs").then((n) => n.c);
133
+ const { DokployApi } = await import("./sniffer-vAXsU_4G.mjs").then((n) => n.c);
133
134
  return new DokployApi({
134
135
  baseUrl: endpoint,
135
136
  token
@@ -2035,9 +2036,9 @@ async function workspaceDevCommand(configured, options) {
2035
2036
  for (const { id, port } of fakes) logger$5.log(`🎭 ${id} fake: http://localhost:${port}`);
2036
2037
  logger$5.log(options.migrate || options.seed ? "🗄️ Migrating the databases" : "🗄️ Checking for pending migrations");
2037
2038
  if (options.migrate || options.seed) {
2038
- const { prepareDevDatabases } = await import("./migrate-BWPuwiXk.mjs");
2039
+ const { prepareDevDatabases } = await import("./migrate-DiJT84g9.mjs");
2039
2040
  await prepareDevDatabases(workspace, reconciled.env, { seed: !!options.seed });
2040
- } else await import("./migrate-BWPuwiXk.mjs").then(({ reportPendingMigrations }) => reportPendingMigrations(workspace, reconciled.env)).catch((error) => {
2041
+ } else await import("./migrate-DiJT84g9.mjs").then(({ reportPendingMigrations }) => reportPendingMigrations(workspace, reconciled.env)).catch((error) => {
2041
2042
  logger$5.log(`⚠️ Could not check for pending migrations: ${error instanceof Error ? error.message : String(error)}`);
2042
2043
  });
2043
2044
  const appUrls = {};
@@ -3417,7 +3418,7 @@ async function buildApp(input) {
3417
3418
  if (production?.bundle && !input.skipBundle) {
3418
3419
  const outputDir = join(appRoot, ".gkm", "server");
3419
3420
  const entryPoint = await writeSurfaceServer(outputDir, production);
3420
- const { bundleServer } = await import("./bundler-C-w7aGoZ.mjs");
3421
+ const { bundleServer } = await import("./bundler-DJlsYzm7.mjs");
3421
3422
  await bundleServer({
3422
3423
  entryPoint,
3423
3424
  outputDir: join(outputDir, "dist"),
@@ -3555,7 +3556,7 @@ async function buildForTarget(target, context, appRoot, workspaceRoot, endpointG
3555
3556
  let masterKey;
3556
3557
  if (context.production?.bundle && !skipBundle) {
3557
3558
  logger$4.log(`\n📦 Bundling production server...`);
3558
- const { bundleServer } = await import("./bundler-C-w7aGoZ.mjs");
3559
+ const { bundleServer } = await import("./bundler-DJlsYzm7.mjs");
3559
3560
  const allConstructs = [
3560
3561
  ...endpoints.map((e) => e.construct),
3561
3562
  ...functions.map((f) => f.construct),
@@ -3807,9 +3808,11 @@ async function composeCommand(options, deps = {}) {
3807
3808
  const { workspace } = await loadWorkspaceConfig(cwd);
3808
3809
  const { stage } = options;
3809
3810
  if (options.down) {
3811
+ const override = stackOverrideFile(workspace.root, stage);
3810
3812
  const ref = {
3811
3813
  project: composeProject(deployIdentity(workspace, stage)),
3812
3814
  file: join(workspace.root, stackDir(stage), "docker-compose.yml"),
3815
+ ...existsSync(override) ? { overrides: [override] } : {},
3813
3816
  cwd: workspace.root
3814
3817
  };
3815
3818
  await (deps.docker ?? dockerCompose).down(ref);
@@ -5252,25 +5255,25 @@ function loadPackageJson() {
5252
5255
  * Run: pnpm --filter @geekmidas/cli sync-versions
5253
5256
  */
5254
5257
  const GEEKMIDAS_VERSIONS = {
5255
- "@geekmidas/audit": "~10.0.0-alpha.68",
5256
- "@geekmidas/auth": "~10.0.0-alpha.68",
5257
- "@geekmidas/cache": "~10.0.0-alpha.68",
5258
- "@geekmidas/client": "~10.0.0-alpha.68",
5259
- "@geekmidas/cloud": "~10.0.0-alpha.68",
5260
- "@geekmidas/constructs": "~10.0.0-alpha.68",
5261
- "@geekmidas/db": "~10.0.0-alpha.68",
5262
- "@geekmidas/emailkit": "~10.0.0-alpha.68",
5263
- "@geekmidas/envkit": "~10.0.0-alpha.68",
5264
- "@geekmidas/errors": "~10.0.0-alpha.68",
5265
- "@geekmidas/events": "~10.0.0-alpha.68",
5266
- "@geekmidas/logger": "~10.0.0-alpha.68",
5267
- "@geekmidas/manifest": "~10.0.0-alpha.68",
5268
- "@geekmidas/rate-limit": "~10.0.0-alpha.68",
5269
- "@geekmidas/schema": "~10.0.0-alpha.68",
5270
- "@geekmidas/services": "~10.0.0-alpha.68",
5271
- "@geekmidas/storage": "~10.0.0-alpha.68",
5272
- "@geekmidas/telescope": "~10.0.0-alpha.68",
5273
- "@geekmidas/testkit": "~10.0.0-alpha.68",
5258
+ "@geekmidas/audit": "~10.0.0-alpha.70",
5259
+ "@geekmidas/auth": "~10.0.0-alpha.70",
5260
+ "@geekmidas/cache": "~10.0.0-alpha.70",
5261
+ "@geekmidas/client": "~10.0.0-alpha.70",
5262
+ "@geekmidas/cloud": "~10.0.0-alpha.70",
5263
+ "@geekmidas/constructs": "~10.0.0-alpha.70",
5264
+ "@geekmidas/db": "~10.0.0-alpha.70",
5265
+ "@geekmidas/emailkit": "~10.0.0-alpha.70",
5266
+ "@geekmidas/envkit": "~10.0.0-alpha.70",
5267
+ "@geekmidas/errors": "~10.0.0-alpha.70",
5268
+ "@geekmidas/events": "~10.0.0-alpha.70",
5269
+ "@geekmidas/logger": "~10.0.0-alpha.70",
5270
+ "@geekmidas/manifest": "~10.0.0-alpha.70",
5271
+ "@geekmidas/rate-limit": "~10.0.0-alpha.70",
5272
+ "@geekmidas/schema": "~10.0.0-alpha.70",
5273
+ "@geekmidas/services": "~10.0.0-alpha.70",
5274
+ "@geekmidas/storage": "~10.0.0-alpha.70",
5275
+ "@geekmidas/telescope": "~10.0.0-alpha.70",
5276
+ "@geekmidas/testkit": "~10.0.0-alpha.70",
5274
5277
  "@geekmidas/cli": `~${loadPackageJson().version}`
5275
5278
  };
5276
5279
  //#endregion
@@ -10501,10 +10504,37 @@ async function secretsSetCommand(key, value, options) {
10501
10504
  logger$2.error(`Secrets not found for stage "${stage}". Run "gkm secrets:init --stage ${stage}" first.`);
10502
10505
  process.exit(1);
10503
10506
  }
10507
+ await assertCredentialValue(key, secretValue, stage);
10504
10508
  await store.write(stage, withCustomSecret(secrets, key, secretValue));
10505
10509
  logger$2.log(`\n✓ Secret "${key}" set for stage "${stage}" (${store.name})`);
10506
10510
  }
10507
10511
  /**
10512
+ * A third party's credentials, checked against the schema of the construct
10513
+ * that reads them before they are stored — what the app would otherwise
10514
+ * refuse as it starts. Only a `<ID>_CREDENTIALS` key in a workspace is
10515
+ * looked at, so setting anything else loads no construct.
10516
+ *
10517
+ * @throws {CredentialsInvalid} listing each issue; nothing is saved
10518
+ */
10519
+ async function assertCredentialValue(key, value, stage) {
10520
+ if (!key.endsWith("_CREDENTIALS")) return;
10521
+ let workspace;
10522
+ try {
10523
+ workspace = await loadWorkspaceSettings();
10524
+ } catch (error) {
10525
+ if (error instanceof ConfigNotFound) return;
10526
+ throw error;
10527
+ }
10528
+ const check = await (await loadCredentialSchemas({
10529
+ root: workspace.root,
10530
+ patterns: constructGlobs(workspace)
10531
+ })).check(key, value);
10532
+ if (!check.ok) throw new CredentialsInvalid(stage, [{
10533
+ key,
10534
+ issues: check.issues
10535
+ }], "set");
10536
+ }
10537
+ /**
10508
10538
  * Show secrets for a stage.
10509
10539
  */
10510
10540
  async function secretsShowCommand(options) {
@@ -11033,8 +11063,8 @@ function testDatabases(reconciled) {
11033
11063
  * starts without the reference data the app needs.
11034
11064
  */
11035
11065
  async function migrateTestStage(workspace, env) {
11036
- const { migrateAndSeed } = await import("./migrate-BWPuwiXk.mjs");
11037
- const { discover } = await import("./discover-BFoJWKGD.mjs").then((n) => n.i);
11066
+ const { migrateAndSeed } = await import("./migrate-DiJT84g9.mjs");
11067
+ const { discover } = await import("./discover-Buwf1z4P.mjs").then((n) => n.i);
11038
11068
  const sources = {};
11039
11069
  const manifest = await discover({
11040
11070
  patterns: constructGlobs(workspace),
@@ -11464,7 +11494,7 @@ program.command("migrate").description("Apply each database construct's migratio
11464
11494
  try {
11465
11495
  const globalOptions = program.opts();
11466
11496
  if (globalOptions.cwd) process.chdir(globalOptions.cwd);
11467
- const { migrateCommand } = await import("./migrate-BWPuwiXk.mjs");
11497
+ const { migrateCommand } = await import("./migrate-DiJT84g9.mjs");
11468
11498
  await migrateCommand({
11469
11499
  ...options,
11470
11500
  ...construct ? { construct } : {}
@@ -11478,7 +11508,7 @@ program.command("seed").description("Migrate, then run each database construct's
11478
11508
  try {
11479
11509
  const globalOptions = program.opts();
11480
11510
  if (globalOptions.cwd) process.chdir(globalOptions.cwd);
11481
- const { seedCommand } = await import("./migrate-BWPuwiXk.mjs");
11511
+ const { seedCommand } = await import("./migrate-DiJT84g9.mjs");
11482
11512
  await seedCommand({
11483
11513
  ...options,
11484
11514
  ...construct ? { construct } : {}
@@ -11492,7 +11522,7 @@ program.command("migration").description("Write a construct's next migration: an
11492
11522
  try {
11493
11523
  const globalOptions = program.opts();
11494
11524
  if (globalOptions.cwd) process.chdir(globalOptions.cwd);
11495
- const { migrationCommand } = await import("./migrate-BWPuwiXk.mjs");
11525
+ const { migrationCommand } = await import("./migrate-DiJT84g9.mjs");
11496
11526
  await migrationCommand({
11497
11527
  construct,
11498
11528
  ...name ? { name } : {}
@@ -11582,11 +11612,22 @@ program.command("secrets:set").description("Set a custom secret for a stage").ar
11582
11612
  process.exit(1);
11583
11613
  }
11584
11614
  });
11615
+ program.command("secrets:add").description("Build the keys a stage must be given — buckets, mail, file servers, third parties' credentials — across every app").requiredOption("--stage <stage>", "Stage name").option("--missing", "Only the keys the stage has not set").option("--json", "Print the keys as JSON and ask nothing").action(async (options) => {
11616
+ try {
11617
+ const globalOptions = program.opts();
11618
+ if (globalOptions.cwd) process.chdir(globalOptions.cwd);
11619
+ const { secretsAddCommand } = await import("./add-BuviRszv.mjs");
11620
+ await secretsAddCommand(options);
11621
+ } catch (error) {
11622
+ console.error(formatError(error));
11623
+ process.exit(1);
11624
+ }
11625
+ });
11585
11626
  program.command("encryption:rotate").description("Add a new current key to an Encryption construct's keyring on a server stage").argument("<construct>", "The Encryption construct (e.g. Pii)").requiredOption("--stage <stage>", "A deployed stage").action(async (construct, options) => {
11586
11627
  try {
11587
11628
  const globalOptions = program.opts();
11588
11629
  if (globalOptions.cwd) process.chdir(globalOptions.cwd);
11589
- const { encryptionRotateCommand } = await import("./encryption-DSiLau1-.mjs");
11630
+ const { encryptionRotateCommand } = await import("./encryption-DR-py9GX.mjs");
11590
11631
  await encryptionRotateCommand(construct, options);
11591
11632
  } catch (error) {
11592
11633
  console.error(formatError(error));
@@ -11597,7 +11638,7 @@ program.command("encryption:retire").description("Remove an old key from an Encr
11597
11638
  try {
11598
11639
  const globalOptions = program.opts();
11599
11640
  if (globalOptions.cwd) process.chdir(globalOptions.cwd);
11600
- const { encryptionRetireCommand } = await import("./encryption-DSiLau1-.mjs");
11641
+ const { encryptionRetireCommand } = await import("./encryption-DR-py9GX.mjs");
11601
11642
  await encryptionRetireCommand(construct, key, options);
11602
11643
  } catch (error) {
11603
11644
  console.error(formatError(error));
@@ -11640,7 +11681,7 @@ program.command("secrets:reconcile").description("Backfill missing custom secret
11640
11681
  if (globalOptions.cwd) process.chdir(globalOptions.cwd);
11641
11682
  const { loadWorkspaceConfig } = await import("./config.mjs");
11642
11683
  const { reconcileMissingSecrets } = await import("./reconcile--I7V4Klj.mjs");
11643
- const { secretsStoreFor } = await import("./state-Bn5JDMFT.mjs").then((n) => n.Nt);
11684
+ const { secretsStoreFor } = await import("./state-527OmqvN.mjs").then((n) => n.Lt);
11644
11685
  const { workspace } = await loadWorkspaceConfig();
11645
11686
  const stage = options.stage ?? workspace.stages.local;
11646
11687
  const store = await secretsStoreFor(workspace, stage);
@@ -11649,7 +11690,7 @@ program.command("secrets:reconcile").description("Backfill missing custom secret
11649
11690
  console.error(`No secrets found for stage "${stage}". Run "gkm secrets:init --stage ${stage}" first.`);
11650
11691
  process.exit(1);
11651
11692
  }
11652
- const { derivedContainers } = await import("./state-Bn5JDMFT.mjs").then((n) => n.W);
11693
+ const { derivedContainers } = await import("./state-527OmqvN.mjs").then((n) => n.J);
11653
11694
  const result = reconcileMissingSecrets(secrets, workspace, await derivedContainers(workspace, stage));
11654
11695
  if (!result) {
11655
11696
  console.log(`\n✓ Secrets for stage "${stage}" are up-to-date`);
@@ -11664,7 +11705,7 @@ program.command("secrets:reconcile").description("Backfill missing custom secret
11664
11705
  }
11665
11706
  });
11666
11707
  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 <list>", "Server targets: run MinIO and/or Mailpit (minio,mailpit) for mail and buckets the stage's secrets don't configure. Not production-grade").action(async (options) => {
11667
- const { deployCli } = await import("./cli-Ce4pLL5O.mjs");
11708
+ const { deployCli } = await import("./cli-BjnqVnE6.mjs");
11668
11709
  const globalOptions = program.opts();
11669
11710
  const code = await deployCli({
11670
11711
  cwd: resolve(globalOptions.cwd ?? process.cwd()),
@@ -11681,8 +11722,8 @@ program.command("deploy").description("Deploy a stage through its target").optio
11681
11722
  });
11682
11723
  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) => {
11683
11724
  try {
11684
- const { rollbackStage } = await import("./rollback-ZlsbQOvj.mjs").then((n) => n.a);
11685
- const { terminalCredentials } = await import("./terminal-C3cv-OQu.mjs");
11725
+ const { rollbackStage } = await import("./rollback-Bw9kESjz.mjs").then((n) => n.a);
11726
+ const { terminalCredentials } = await import("./terminal-C6TBo_SA.mjs");
11686
11727
  const globalOptions = program.opts();
11687
11728
  await rollbackStage({
11688
11729
  cwd: resolve(globalOptions.cwd ?? process.cwd()),
@@ -11717,7 +11758,7 @@ program.command("deploy:github").description("Let GitHub Actions deploy a stage:
11717
11758
  try {
11718
11759
  const globalOptions = program.opts();
11719
11760
  if (globalOptions.cwd) process.chdir(globalOptions.cwd);
11720
- const { deployGithubCommand } = await import("./github-yy6WpHIl.mjs");
11761
+ const { deployGithubCommand } = await import("./github-D2pYzY7L.mjs");
11721
11762
  await deployGithubCommand(options);
11722
11763
  } catch (error) {
11723
11764
  console.error(formatError(error));