Setting DASHBOARD_AND_API_DISABLED=true will now disable the remix routes

This commit is contained in:
Eric Allam
2024-03-18 14:58:34 +00:00
parent 49e9dd8cb2
commit 479d355b7b
+12 -8
View File
@@ -68,16 +68,20 @@ if (process.env.HTTP_SERVER_DISABLED !== "true") {
next();
});
app.all(
"*",
createRequestHandler({
build,
mode: MODE,
})
);
if (process.env.DASHBOARD_AND_API_DISABLED !== "true") {
app.all(
"*",
createRequestHandler({
build,
mode: MODE,
})
);
}
const server = app.listen(port, () => {
console.log(`app ready: http://localhost:${port} [NODE_ENV: ${MODE}]`);
console.log(`server ready: http://localhost:${port} [NODE_ENV: ${MODE}]`);
if (MODE === "development") {
broadcastDevReady(build)