fix(wizard): honor MOSAIC_GATEWAY_SKIP_NPM_INSTALL — unblock install.sh --dev gateway testing #698

Merged
jason.woltje merged 2 commits from fix/gateway-config-honor-skip-env into next 2026-07-10 01:30:11 +00:00
Showing only changes of commit 4e28966fd0 - Show all commits

View File

@@ -294,7 +294,12 @@ export async function gatewayConfigStage(
}
// Install the gateway npm package on first install or after failure.
if (!opts.skipInstall && !daemonRunning) {
// MOSAIC_GATEWAY_SKIP_NPM_INSTALL=1 forces a skip even without opts.skipInstall:
// used by dev/offline installs where @mosaicstack/gateway is already present
// globally (e.g. a build-from-source `install.sh --dev`) and must not be
// overwritten by the registry @latest build.
const skipNpmInstall = opts.skipInstall || process.env['MOSAIC_GATEWAY_SKIP_NPM_INSTALL'] === '1';
if (!skipNpmInstall && !daemonRunning) {
installGatewayPackage();
}