diff --git a/bizmatch-server/src/drizzle/drizzle.module.ts b/bizmatch-server/src/drizzle/drizzle.module.ts index 2e94f52..9aa2803 100644 --- a/bizmatch-server/src/drizzle/drizzle.module.ts +++ b/bizmatch-server/src/drizzle/drizzle.module.ts @@ -9,14 +9,20 @@ import * as schema from './schema'; import { PG_CONNECTION } from './schema'; const { Pool } = pkg; @Module({ - imports: [ConfigModule], + imports: [ConfigModule], providers: [ { provide: PG_CONNECTION, inject: [ConfigService, WINSTON_MODULE_PROVIDER, ClsService], useFactory: async (configService: ConfigService, logger: Logger, cls: ClsService) => { const connectionString = configService.get('DATABASE_URL'); - console.log('--->',connectionString) + const dbHost = configService.get('DB_HOST'); + const dbPort = configService.get('DB_PORT'); + const dbName = configService.get('DB_NAME'); + const dbUser = configService.get('DB_USER'); + const dbPassword = configService.get('DB_PASSWORD'); + logger.info(`Drizzle Connection - URL: ${connectionString}, Host: ${dbHost}, Port: ${dbPort}, DB: ${dbName}, User: ${dbUser}`); + console.log(`---> Drizzle Connection - URL: ${connectionString}, Host: ${dbHost}, Port: ${dbPort}, DB: ${dbName}, User: ${dbUser}`); const pool = new Pool({ connectionString, // ssl: true, // Falls benötigt