Initial commit

This commit is contained in:
2022-12-24 14:32:13 +01:00
commit 3996e37682
17 changed files with 10283 additions and 0 deletions
+19
View File
@@ -0,0 +1,19 @@
import * as dotenv from 'dotenv';
const mariadb = require('mariadb');
dotenv.config();
export namespace NachklangCalendarDB {
const pool = mariadb.createPool({
host: process.env.DB_HOST,
user: process.env.DB_USER,
password: process.env.DB_PASSWORD,
database: process.env.CALENDAR_DB,
connectionLimit: 5
});
export const getConnection = async () => {
return pool.getConnection();
};
}