feat(CF-368): Use pgbouncer connection pooling via POSTGRES_PORT env
Changed hardcoded port 5432 to read from POSTGRES_PORT environment variable to support pgbouncer connection pooling (port 6432). Connection pooling reduces overhead for frequent queries and better handles concurrent connections. .env now configured with POSTGRES_PORT=6432 (pgbouncer). Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -5,7 +5,7 @@ const { Pool } = pg;
|
||||
// Uses DNS hostname (infra.agiliton.internal) via WireGuard DNS
|
||||
const config = {
|
||||
host: process.env.POSTGRES_HOST || 'infra.agiliton.internal',
|
||||
port: 5432,
|
||||
port: parseInt(process.env.POSTGRES_PORT || '5432'),
|
||||
database: 'agiliton',
|
||||
user: 'agiliton',
|
||||
password: 'QtqiwCOAUpQNF6pjzOMAREzUny2bY8V1',
|
||||
|
||||
Reference in New Issue
Block a user