From 27926728047287adea6010923da09b85ee392e23 Mon Sep 17 00:00:00 2001 From: coodos Date: Thu, 26 Feb 2026 13:40:22 +0530 Subject: [PATCH] fix: .env path resolution on registry --- platforms/registry/api/src/config/database.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/platforms/registry/api/src/config/database.ts b/platforms/registry/api/src/config/database.ts index 34d7366f8..2d26a549b 100644 --- a/platforms/registry/api/src/config/database.ts +++ b/platforms/registry/api/src/config/database.ts @@ -5,7 +5,7 @@ import * as dotenv from "dotenv" import { join } from "path" // Load environment variables from root .env file -dotenv.config({ path: join(__dirname, "../../../../.env") }) +dotenv.config({ path: join(__dirname, "../../../../../.env") }) export const AppDataSource = new DataSource({ type: "postgres", @@ -19,9 +19,9 @@ export const AppDataSource = new DataSource({ subscribers: [], ssl: process.env.DB_CA_CERT ? { - rejectUnauthorized: false, - ca: process.env.DB_CA_CERT, - } + rejectUnauthorized: false, + ca: process.env.DB_CA_CERT, + } : false, // Connection pool configuration to prevent exhaustion extra: { @@ -31,4 +31,4 @@ export const AppDataSource = new DataSource({ connectionTimeoutMillis: 5000, statement_timeout: 10000, }, -}) \ No newline at end of file +})