Skip to content

armgit / crm

Public Imported from GitHub
0

Comp AI CRM is an open source, CRM designed for AI agents. Agentic-first CRM.

TypeScript

fix(app): inherit build environment variables (#251)

grim0f0b92842b94
diff --git a/apps/app/test/turbo-config.spec.ts b/apps/app/test/turbo-config.spec.ts
new file mode 100644
index 00000000..0e1de6b9
--- /dev/null
+++ b/apps/app/test/turbo-config.spec.ts
@@ -0,0 +1,11 @@
+import { describe, expect, it } from "bun:test";
+import turboConfig from "../turbo.json";
+
+describe("app build environment", () => {
+ it("extends the root build environment with the public auth URL", () => {
+ expect(turboConfig.tasks.build.env).toEqual([
+ "$TURBO_EXTENDS$",
+ "NEXT_PUBLIC_AUTH_URL",
+ ]);
+ });
+});
diff --git a/apps/app/turbo.json b/apps/app/turbo.json
index cea0ca0e..fd6d8112 100644
--- a/apps/app/turbo.json
+++ b/apps/app/turbo.json
@@ -6,7 +6,7 @@
"dependsOn": ["^build"],
"inputs": ["$TURBO_DEFAULT$", ".env*"],
"outputs": [".next/**", "!.next/cache/**", "!.next/dev/**"],
- "env": ["NEXT_PUBLIC_API_URL", "NEXT_PUBLIC_AUTH_URL"],
+ "env": ["$TURBO_EXTENDS$", "NEXT_PUBLIC_AUTH_URL"],
"passThroughEnv": [
"AGENT_BRIDGE_SECRET",
"AGENT_URL",