chore: DB defaults for managed platform, reduce required env vars

- db.js: DB_HOST default postgresqlk8s-master, DB_NAME default ipwhitelist, DB_USER default super
- server.js: fail-fast for DB_PASS in production (instead of IAM_API_URL)
- After this change: only DB_PASS is required for mock mode
This commit is contained in:
2026-06-09 19:20:29 +04:00
parent 393595301b
commit 9fd808bc1f
5 changed files with 321 additions and 5 deletions
+2 -2
View File
@@ -70,8 +70,8 @@ async function start() {
console.error('FATAL: SESSION_SECRET не задан или равен дефолту в production!');
process.exit(1);
}
if (!process.env.IAM_API_URL) {
console.error('FATAL: IAM_API_URL не задан в production!');
if (!process.env.DB_PASS) {
console.error('FATAL: DB_PASS не задан в production!');
process.exit(1);
}
}