Skip to content

Open-source Grok Bot alternative for named AI teammates. Local-first desktop, web, and mobile clients with per-bot tools, instructions, and memory. Independent fork of T3 Code.

run backend as node

Julius Marminge4fff00c8c3be
diff --git a/apps/desktop/src/main.ts b/apps/desktop/src/main.ts
index a0c9c4692..a1f7a9bf2 100644
--- a/apps/desktop/src/main.ts
+++ b/apps/desktop/src/main.ts
@@ -83,7 +83,12 @@ function startBackend(): void {
const child = spawn(process.execPath, [BACKEND_ENTRY], {
cwd: ROOT_DIR,
- env: backendEnv(),
+ // In Electron main, process.execPath points to the Electron binary.
+ // Run the child in Node mode so this backend process does not become a GUI app instance.
+ env: {
+ ...backendEnv(),
+ ELECTRON_RUN_AS_NODE: "1",
+ },
stdio: "inherit",
});
backendProcess = child;