From 04f72995c59d92e493a8de6b7b923840b0af2a1f Mon Sep 17 00:00:00 2001 From: zomars Date: Thu, 28 Apr 2022 12:43:22 -0600 Subject: [PATCH] Allows to use local prisma env --- packages/prisma/env.ts | 4 ++++ scripts/getEnvSecrets.ts | 2 ++ 2 files changed, 6 insertions(+) create mode 100644 packages/prisma/env.ts diff --git a/packages/prisma/env.ts b/packages/prisma/env.ts new file mode 100644 index 0000000000..00c09ae543 --- /dev/null +++ b/packages/prisma/env.ts @@ -0,0 +1,4 @@ +import { config } from "dotenv"; +import { resolve } from "path"; + +config({ path: resolve(__dirname, "./.env") }); diff --git a/scripts/getEnvSecrets.ts b/scripts/getEnvSecrets.ts index 0dc197825e..2ed0e66eb8 100644 --- a/scripts/getEnvSecrets.ts +++ b/scripts/getEnvSecrets.ts @@ -1,5 +1,7 @@ import { Client, Pool } from "pg"; +import "@calcom/prisma/env"; + const connectionString = process.env.DATABASE_URL; const pool = new Pool({