create and restore backups

This commit is contained in:
Julian Krauser 2025-01-29 16:49:34 +01:00
parent 6ae463a784
commit f78097b616
16 changed files with 696 additions and 21 deletions

View file

@ -24,9 +24,9 @@ export const MAIL_SECURE = process.env.MAIL_SECURE ?? "false";
export const CLUB_NAME = process.env.CLUB_NAME ?? "FF Admin";
export const CLUB_WEBSITE = process.env.CLUB_WEBSITE ?? "";
export const BACKUP_INTERVAL = Number(process.env.CLUB_WEBSITE ?? "0");
export const BACKUP_COPIES = Number(process.env.CLUB_WEBSITE ?? "0");
export const BACKUP_AUTO_RESTORE = process.env.CLUB_WEBSITE ?? "false";
export const BACKUP_INTERVAL = Number(process.env.BACKUP_INTERVAL ?? "0");
export const BACKUP_COPIES = Number(process.env.BACKUP_COPIES ?? "0");
export const BACKUP_AUTO_RESTORE = process.env.BACKUP_AUTO_RESTORE ?? "false";
export function configCheck() {
if (DB_TYPE != "mysql" && DB_TYPE != "sqlite") throw new Error("set valid value to DB_TYPE (mysql|sqlite)");