DB Auswahl in .env

This commit is contained in:
Klaas Börgmann 2025-03-08 14:44:23 +01:00
parent dd1c4e4c63
commit bac63bbde9
4 changed files with 6 additions and 4 deletions

BIN
.DS_Store vendored

Binary file not shown.

View File

@ -1,4 +1,5 @@
DATABASE_URL=postgres://user:psw@localhost:5432/postgres DATABASE_URL=postgres://user:psw@localhost:5432/
DB=postgres
SESSIONSECRET=Your Secret SESSIONSECRET=Your Secret
MAILHOST= MAILHOST=
MAILUSER= MAILUSER=
@ -9,4 +10,4 @@ TELEBOT=
TELECHAT= TELECHAT=
HOST= HOST=
WEEKDAY=4 WEEKDAY=4
ABTEILUNG=KiTu/ABENTEUERSPIELPLATZ/KKT ABTEILUNG=KiTu/ABENTEUERSPIELPLATZ/KKT

3
.gitignore vendored
View File

@ -1,3 +1,4 @@
.env .env
node_modules/ node_modules/
logs/* .DS_Store
logs/*

2
app.js
View File

@ -82,7 +82,7 @@ const transporter = nodemailer.createTransport({
// Datenbankverbindung // Datenbankverbindung
const pool = new Pool({ const pool = new Pool({
connectionString: process.env.DATABASE_URL + "tkd", connectionString: process.env.DATABASE_URL + process.env.DB,
}); });
const poolNew = new Pool({ const poolNew = new Pool({