betterstart-cli 0.0.76 → 0.0.77
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/cli.js +25 -16
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -23561,24 +23561,33 @@ ${logs.stderr}`);
|
|
|
23561
23561
|
}
|
|
23562
23562
|
async function runRailwayDeployFlow(options) {
|
|
23563
23563
|
try {
|
|
23564
|
-
const
|
|
23565
|
-
|
|
23566
|
-
|
|
23567
|
-
|
|
23568
|
-
|
|
23569
|
-
|
|
23570
|
-
|
|
23571
|
-
|
|
23564
|
+
const prepSpinner = spinner2();
|
|
23565
|
+
prepSpinner.start("Connecting the Railway web service");
|
|
23566
|
+
let service;
|
|
23567
|
+
let url;
|
|
23568
|
+
try {
|
|
23569
|
+
service = await ensureRailwayAppService(
|
|
23570
|
+
options.session,
|
|
23571
|
+
options.cwd,
|
|
23572
|
+
options.service?.trim() || "web"
|
|
23573
|
+
);
|
|
23574
|
+
if ((service.replicaCount ?? 1) > 1) {
|
|
23575
|
+
throw new Error(
|
|
23576
|
+
`Railway service ${service.name} has ${service.replicaCount} replicas. BetterStart Railway v1 supports one replica because Next.js cache invalidation is process-local.`
|
|
23577
|
+
);
|
|
23578
|
+
}
|
|
23579
|
+
await linkRailwayService(
|
|
23580
|
+
options.session.runner,
|
|
23581
|
+
options.cwd,
|
|
23582
|
+
options.session.project,
|
|
23583
|
+
service,
|
|
23584
|
+
options.session.env
|
|
23572
23585
|
);
|
|
23586
|
+
prepSpinner.message("Setting up the Railway domain");
|
|
23587
|
+
url = await ensureRailwayDomain(options.session, options.cwd, service);
|
|
23588
|
+
} finally {
|
|
23589
|
+
prepSpinner.clear();
|
|
23573
23590
|
}
|
|
23574
|
-
await linkRailwayService(
|
|
23575
|
-
options.session.runner,
|
|
23576
|
-
options.cwd,
|
|
23577
|
-
options.session.project,
|
|
23578
|
-
service,
|
|
23579
|
-
options.session.env
|
|
23580
|
-
);
|
|
23581
|
-
const url = await ensureRailwayDomain(options.session, options.cwd, service);
|
|
23582
23591
|
if (!url) {
|
|
23583
23592
|
throw new Error("Railway could not create a public domain required for Better Auth.");
|
|
23584
23593
|
}
|