hazo_env 0.14.2 → 0.15.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGE_LOG.md +19 -0
- package/dist/cli.js +6 -0
- package/dist/deploy/build.js +1 -1
- package/dist/deploy/init.d.ts +2 -0
- package/dist/deploy/init.d.ts.map +1 -1
- package/dist/deploy/init.js +15 -1
- package/dist/deploy/pm2-start.d.ts +2 -0
- package/dist/deploy/pm2-start.d.ts.map +1 -1
- package/dist/deploy/pm2-start.js +2 -2
- package/dist/deploy/rollback.d.ts.map +1 -1
- package/dist/deploy/rollback.js +1 -0
- package/dist/deploy/switch.d.ts.map +1 -1
- package/dist/deploy/switch.js +1 -0
- package/dist/deploy/types.d.ts +6 -0
- package/dist/deploy/types.d.ts.map +1 -1
- package/dist/resolve/deploy.d.ts.map +1 -1
- package/dist/resolve/deploy.js +10 -0
- package/package.json +1 -1
package/CHANGE_LOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# hazo_env — Change Log
|
|
2
2
|
|
|
3
|
+
## 0.15.0 — 2026-11-23
|
|
4
|
+
|
|
5
|
+
New: `deploy init` now copies gitignored env files (`.env.local`,
|
|
6
|
+
`.env.production`, etc.) from the live directory to the freshly-cloned peer.
|
|
7
|
+
|
|
8
|
+
- **`env_files`** config field (`[deploy]` section): comma-separated list of
|
|
9
|
+
files to copy. Default: `.env.local`. Kinstripe sets
|
|
10
|
+
`env_files = .env.local, .env.production`.
|
|
11
|
+
- **`RunInitResult`**: gains `envFilesCopied` and `envFilesMissing` arrays.
|
|
12
|
+
- **CLI**: `deploy init` output now reports which env files were copied and
|
|
13
|
+
warns about any that were listed but not found.
|
|
14
|
+
|
|
15
|
+
Fix: all `startNamedPm2Process` callers (`deploy build`, `deploy switch`,
|
|
16
|
+
`deploy rollback`) now pass `selectAppName: config.app_name`, so multi-app
|
|
17
|
+
ecosystem files (e.g. Kinstripe's 5-app `ecosystem.config.cjs`) work
|
|
18
|
+
instead of throwing "only supports a single-app ecosystem file".
|
|
19
|
+
|
|
20
|
+
Also includes the 0.14.1/0.14.2 fix (resolvePeerDir configSuffix).
|
|
21
|
+
|
|
3
22
|
## 0.14.2 — 2026-11-23
|
|
4
23
|
|
|
5
24
|
Republish of 0.14.1 — the 0.14.1 tarball was published with a stale dist/
|
package/dist/cli.js
CHANGED
|
@@ -275,6 +275,12 @@ async function runDeployInit() {
|
|
|
275
275
|
const result = runInit(config, nodeCommandRunner);
|
|
276
276
|
console.log(` ${pc.green('✓')} Peer directory created: ${result.peerDir}`);
|
|
277
277
|
console.log(` ${pc.dim(`cloned from ${result.originUrl}`)}`);
|
|
278
|
+
if (result.envFilesCopied.length) {
|
|
279
|
+
console.log(` ${pc.green('✓')} Env files copied: ${result.envFilesCopied.join(', ')}`);
|
|
280
|
+
}
|
|
281
|
+
if (result.envFilesMissing.length) {
|
|
282
|
+
console.log(` ${pc.yellow('⚠')} Env files not found (copy manually): ${result.envFilesMissing.join(', ')}`);
|
|
283
|
+
}
|
|
278
284
|
console.log('');
|
|
279
285
|
console.log(` Next steps:`);
|
|
280
286
|
console.log(` cd ${result.peerDir}`);
|
package/dist/deploy/build.js
CHANGED
|
@@ -353,7 +353,7 @@ export function runBuild(config, runner, opts = {}) {
|
|
|
353
353
|
warnings.push(detail);
|
|
354
354
|
pass('clean-stale-staging', detail);
|
|
355
355
|
}
|
|
356
|
-
runStep('start-staging', () => startNamedPm2Process(runner, { dir: cwd, name: stagingProcessName, port: config.staging_port }));
|
|
356
|
+
runStep('start-staging', () => startNamedPm2Process(runner, { dir: cwd, name: stagingProcessName, port: config.staging_port, selectAppName: config.app_name }));
|
|
357
357
|
pass('start-staging', `name=${stagingProcessName} PORT=${config.staging_port}, cwd=${cwd}`);
|
|
358
358
|
// Step 10: health check, retried — pm2 start returns before the app has
|
|
359
359
|
// actually finished booting.
|
package/dist/deploy/init.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../../src/deploy/init.ts"],"names":[],"mappings":"AAqBA,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAe,MAAM,YAAY,CAAC;AAgD3E,MAAM,WAAW,cAAc;IAC7B,iFAAiF;IACjF,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,oEAAoE;IACpE,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,aAAa;IAC5B,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../../src/deploy/init.ts"],"names":[],"mappings":"AAqBA,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAe,MAAM,YAAY,CAAC;AAgD3E,MAAM,WAAW,cAAc;IAC7B,iFAAiF;IACjF,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,oEAAoE;IACpE,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,aAAa;IAC5B,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB,eAAe,EAAE,MAAM,EAAE,CAAC;CAC3B;AA0CD;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,aAAa,EAAE,IAAI,GAAE,cAAmB,GAAG,aAAa,CA8C7G"}
|
package/dist/deploy/init.js
CHANGED
|
@@ -119,6 +119,20 @@ export function runInit(config, runner, opts = {}) {
|
|
|
119
119
|
fs.mkdirSync(path.dirname(peerIniPath), { recursive: true });
|
|
120
120
|
fs.writeFileSync(peerIniPath, swappedIni, 'utf-8');
|
|
121
121
|
ensurePeerDataDir(config, peerIniPath, peerDir);
|
|
122
|
+
const envFilesCopied = [];
|
|
123
|
+
const envFilesMissing = [];
|
|
124
|
+
for (const envFile of config.env_files) {
|
|
125
|
+
const src = path.join(currentDir, envFile);
|
|
126
|
+
const dest = path.join(peerDir, envFile);
|
|
127
|
+
if (fs.existsSync(src)) {
|
|
128
|
+
fs.mkdirSync(path.dirname(dest), { recursive: true });
|
|
129
|
+
fs.copyFileSync(src, dest);
|
|
130
|
+
envFilesCopied.push(envFile);
|
|
131
|
+
}
|
|
132
|
+
else {
|
|
133
|
+
envFilesMissing.push(envFile);
|
|
134
|
+
}
|
|
135
|
+
}
|
|
122
136
|
const state = {
|
|
123
137
|
app_name: config.app_name,
|
|
124
138
|
live_dir: currentDir,
|
|
@@ -127,5 +141,5 @@ export function runInit(config, runner, opts = {}) {
|
|
|
127
141
|
staging_port: config.staging_port,
|
|
128
142
|
};
|
|
129
143
|
writeState(state);
|
|
130
|
-
return { currentDir, peerDir, originUrl };
|
|
144
|
+
return { currentDir, peerDir, originUrl, envFilesCopied, envFilesMissing };
|
|
131
145
|
}
|
|
@@ -53,6 +53,8 @@ export interface PromoteDirFreshOptions {
|
|
|
53
53
|
toLabel: string;
|
|
54
54
|
/** Describes `fromDir` in the restore-outcome messages, e.g. "the previous live build" or "the build that was live before this rollback attempt". */
|
|
55
55
|
fromLabel: string;
|
|
56
|
+
/** When the ecosystem file has multiple apps, the name of the web-app entry to select as the template. */
|
|
57
|
+
selectAppName?: string;
|
|
56
58
|
}
|
|
57
59
|
export interface PromoteDirFreshResult {
|
|
58
60
|
/** True iff a staging PM2 process was found and deleted (false if stagingName was omitted, or was already stopped/absent). */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pm2-start.d.ts","sourceRoot":"","sources":["../../src/deploy/pm2-start.ts"],"names":[],"mappings":"AAiCA,OAAO,KAAK,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAe/D,MAAM,WAAW,2BAA2B;IAC1C,yEAAyE;IACzE,GAAG,EAAE,MAAM,CAAC;IACZ,g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G,OAAO,CAEnE;AAED,MAAM,WAAW,sBAAsB;IACrC,uEAAuE;IACvE,OAAO,EAAE,MAAM,CAAC;IAChB,uDAAuD;IACvD,KAAK,EAAE,MAAM,CAAC;IACd,8GAA8G;IAC9G,IAAI,EAAE,MAAM,CAAC;IACb,2CAA2C;IAC3C,IAAI,EAAE,MAAM,CAAC;IACb;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,mGAAmG;IACnG,OAAO,EAAE,MAAM,CAAC;IAChB,qJAAqJ;IACrJ,SAAS,EAAE,MAAM,CAAC;IAClB,0GAA0G;IAC1G,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,qBAAqB;IACpC,8HAA8H;IAC9H,cAAc,EAAE,OAAO,CAAC;IACxB;;;;;;;;;;OAUG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAC;CAC/B;AAED,gJAAgJ;AAChJ,qBAAa,oBAAqB,SAAQ,KAAK;gBACjC,OAAO,EAAE,MAAM;CAI5B;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAAE,aAAa,EAAE,IAAI,EAAE,sBAAsB,GAAG,qBAAqB,CA4D1G"}
|
package/dist/deploy/pm2-start.js
CHANGED
|
@@ -244,7 +244,7 @@ export function promoteDirFresh(runner, opts) {
|
|
|
244
244
|
}
|
|
245
245
|
}
|
|
246
246
|
try {
|
|
247
|
-
startNamedPm2Process(runner, { dir: opts.toDir, name: opts.name, port: opts.port });
|
|
247
|
+
startNamedPm2Process(runner, { dir: opts.toDir, name: opts.name, port: opts.port, selectAppName: opts.selectAppName });
|
|
248
248
|
}
|
|
249
249
|
catch (startErr) {
|
|
250
250
|
const startMsg = startErr instanceof Error ? startErr.message : String(startErr);
|
|
@@ -261,7 +261,7 @@ export function promoteDirFresh(runner, opts) {
|
|
|
261
261
|
}
|
|
262
262
|
let restoreMsg;
|
|
263
263
|
try {
|
|
264
|
-
startNamedPm2Process(runner, { dir: opts.fromDir, name: opts.name, port: opts.port });
|
|
264
|
+
startNamedPm2Process(runner, { dir: opts.fromDir, name: opts.name, port: opts.port, selectAppName: opts.selectAppName });
|
|
265
265
|
restoreMsg = `Production RESTORED: ${opts.fromLabel} in ${opts.fromDir} was restarted on port ${opts.port}.`;
|
|
266
266
|
}
|
|
267
267
|
catch (restoreErr) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rollback.d.ts","sourceRoot":"","sources":["../../src/deploy/rollback.ts"],"names":[],"mappings":"AAkFA,OAAO,EAAgB,KAAK,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACpE,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE3E,MAAM,WAAW,iBAAiB;IAChC,eAAe,EAAE,MAAM,CAAC;IACxB,aAAa,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,WAAW,CAAC;IACnB,6GAA6G;IAC7G,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,kHAAkH;IAClH,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB;;;;OAIG;IACH,QAAQ,EAAE,iBAAiB,EAAE,CAAC;CAC/B;AAED,uEAAuE;AACvE,qBAAa,kBAAmB,SAAQ,KAAK;gBAC/B,OAAO,EAAE,MAAM;CAI5B;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,aAAa,GAAG,iBAAiB,
|
|
1
|
+
{"version":3,"file":"rollback.d.ts","sourceRoot":"","sources":["../../src/deploy/rollback.ts"],"names":[],"mappings":"AAkFA,OAAO,EAAgB,KAAK,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACpE,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE3E,MAAM,WAAW,iBAAiB;IAChC,eAAe,EAAE,MAAM,CAAC;IACxB,aAAa,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,WAAW,CAAC;IACnB,6GAA6G;IAC7G,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,kHAAkH;IAClH,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB;;;;OAIG;IACH,QAAQ,EAAE,iBAAiB,EAAE,CAAC;CAC/B;AAED,uEAAuE;AACvE,qBAAa,kBAAmB,SAAQ,KAAK;gBAC/B,OAAO,EAAE,MAAM;CAI5B;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,aAAa,GAAG,iBAAiB,CA2H1F"}
|
package/dist/deploy/rollback.js
CHANGED
|
@@ -151,6 +151,7 @@ export function runRollback(config, runner) {
|
|
|
151
151
|
stagingName: `${config.app_name}-staging`,
|
|
152
152
|
toLabel: 'previous live app',
|
|
153
153
|
fromLabel: 'the build that was live before this rollback attempt',
|
|
154
|
+
selectAppName: config.app_name,
|
|
154
155
|
});
|
|
155
156
|
stagingDeleteWarning = promoteResult.stagingDeleteWarning;
|
|
156
157
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"switch.d.ts","sourceRoot":"","sources":["../../src/deploy/switch.ts"],"names":[],"mappings":"AA8DA,OAAO,EAAgB,KAAK,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACpE,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE3E,MAAM,WAAW,oBAAoB;IACnC,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,eAAe;IAC9B,eAAe,EAAE,MAAM,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,MAAM,C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oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,8GAA8G;IAC9G,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,eAAe,EAAE,oBAAoB,EAAE,CAAC;IACxC,KAAK,EAAE,WAAW,CAAC;IACnB;;;;;;OAMG;IACH,QAAQ,EAAE,iBAAiB,EAAE,CAAC;CAC/B;AAED,uFAAuF;AACvF,qBAAa,gBAAiB,SAAQ,KAAK;gBAC7B,OAAO,EAAE,MAAM;CAI5B;AAED,MAAM,WAAW,gBAAgB;IAC/B;;;;;OAKG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;;;GAGG;AACH,wBAAgB,SAAS,CAAC,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,aAAa,EAAE,IAAI,GAAE,gBAAqB,GAAG,eAAe,CAmInH"}
|
package/dist/deploy/switch.js
CHANGED
|
@@ -125,6 +125,7 @@ export function runSwitch(config, runner, opts = {}) {
|
|
|
125
125
|
stagingName: `${config.app_name}-staging`,
|
|
126
126
|
toLabel: 'standby app',
|
|
127
127
|
fromLabel: 'the previous live build',
|
|
128
|
+
selectAppName: config.app_name,
|
|
128
129
|
});
|
|
129
130
|
stagingStopped = result.stagingDeleted;
|
|
130
131
|
stagingDeleteWarning = result.stagingDeleteWarning;
|
package/dist/deploy/types.d.ts
CHANGED
|
@@ -40,6 +40,12 @@ export interface DeployConfig {
|
|
|
40
40
|
* Default: []
|
|
41
41
|
*/
|
|
42
42
|
sidecar_apps: string[];
|
|
43
|
+
/**
|
|
44
|
+
* Gitignored files (relative to app root) copied from the live dir to the
|
|
45
|
+
* peer during `deploy init` — typically `.env.local`, `.env.production`.
|
|
46
|
+
* Comma-separated in the INI. Default: ['.env.local']
|
|
47
|
+
*/
|
|
48
|
+
env_files: string[];
|
|
43
49
|
}
|
|
44
50
|
/** Result of a single command execution. */
|
|
45
51
|
export interface CommandResult {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/deploy/types.ts"],"names":[],"mappings":"AAMA,8DAA8D;AAC9D,MAAM,WAAW,YAAY;IAC3B,0GAA0G;IAC1G,QAAQ,EAAE,MAAM,CAAC;IACjB,gHAAgH;IAChH,UAAU,EAAE,MAAM,CAAC;IACnB,yCAAyC;IACzC,SAAS,EAAE,MAAM,CAAC;IAClB,yEAAyE;IACzE,YAAY,EAAE,MAAM,CAAC;IACrB,8EAA8E;IAC9E,UAAU,EAAE,MAAM,CAAC;IACnB,6EAA6E;IAC7E,WAAW,EAAE,MAAM,CAAC;IACpB,8EAA8E;IAC9E,aAAa,EAAE,MAAM,CAAC;IACtB,oFAAoF;IACpF,MAAM,EAAE,MAAM,CAAC;IACf,yFAAyF;IACzF,WAAW,EAAE,MAAM,GAAG,MAAM,GAAG,QAAQ,CAAC;IACxC,gEAAgE;IAChE,SAAS,EAAE,MAAM,CAAC;IAClB,gEAAgE;IAChE,WAAW,EAAE,MAAM,CAAC;IACpB,oFAAoF;IACpF,aAAa,EAAE,MAAM,CAAC;IACtB;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,6FAA6F;IAC7F,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAC3B;;;;OAIG;IACH,YAAY,EAAE,MAAM,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/deploy/types.ts"],"names":[],"mappings":"AAMA,8DAA8D;AAC9D,MAAM,WAAW,YAAY;IAC3B,0GAA0G;IAC1G,QAAQ,EAAE,MAAM,CAAC;IACjB,gHAAgH;IAChH,UAAU,EAAE,MAAM,CAAC;IACnB,yCAAyC;IACzC,SAAS,EAAE,MAAM,CAAC;IAClB,yEAAyE;IACzE,YAAY,EAAE,MAAM,CAAC;IACrB,8EAA8E;IAC9E,UAAU,EAAE,MAAM,CAAC;IACnB,6EAA6E;IAC7E,WAAW,EAAE,MAAM,CAAC;IACpB,8EAA8E;IAC9E,aAAa,EAAE,MAA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,MAAM,CAAC;IACrB,2DAA2D;IAC3D,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,uDAAuD;IACvD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,iBAAiB,CAAC,EAAE,SAAS,GAAG,QAAQ,CAAC;IACzC,yDAAyD;IACzD,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,uEAAuE;IACvE,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,yEAAyE;IACzE,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED;;;;;;;;;GASG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../src/resolve/deploy.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../src/resolve/deploy.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AA0GvD;;;;GAIG;AACH,wBAAgB,mBAAmB,IAAI,YAAY,CAyDlD"}
|
package/dist/resolve/deploy.js
CHANGED
|
@@ -98,6 +98,15 @@ function collectSidecarApps(section) {
|
|
|
98
98
|
.map((s) => s.trim())
|
|
99
99
|
.filter((s) => s.length > 0);
|
|
100
100
|
}
|
|
101
|
+
function collectEnvFiles(section) {
|
|
102
|
+
const raw = section['env_files'];
|
|
103
|
+
if (typeof raw !== 'string' || !raw.trim())
|
|
104
|
+
return ['.env.local'];
|
|
105
|
+
return raw
|
|
106
|
+
.split(',')
|
|
107
|
+
.map((s) => s.trim())
|
|
108
|
+
.filter((s) => s.length > 0);
|
|
109
|
+
}
|
|
101
110
|
const VALID_DB_STRATEGIES = new Set(['auto', 'copy', 'shared']);
|
|
102
111
|
/**
|
|
103
112
|
* Resolve the `[deploy]` section of hazo_env_config.ini into a typed
|
|
@@ -154,5 +163,6 @@ export function resolveDeployConfig() {
|
|
|
154
163
|
migrate_cmd: section['migrate_cmd'] ?? DEFAULTS.migrate_cmd,
|
|
155
164
|
post_switch_cmds: collectPostSwitchCmds(section),
|
|
156
165
|
sidecar_apps: collectSidecarApps(section),
|
|
166
|
+
env_files: collectEnvFiles(section),
|
|
157
167
|
};
|
|
158
168
|
}
|
package/package.json
CHANGED