mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-09 13:01:00 +00:00
feat(admin): show the newest database dump on the backups page
GET /api/admin/backups now carries `database`: the newest good dump (when, how big, kept on the server, off-host or both), the newest failed run, whether this server can write its backup directory, and whether off-host copies are configured. The backups card leads with one row built from it, with a notice when the last run failed and when dumps can only go off-host or cannot be taken at all. The route stays an unpublished admin console route, so the OpenAPI document does not change.
This commit is contained in:
1 parent
e665f17f52
commit
3646502a86
14 files changed
+282
-10
No files matched your search
@@ -9,6 +9,7 @@
|
||||
* both sides a route-handler-independent shared type home; the route
|
||||
* keeps owning the HTTP contract, the component keeps owning the UI.
|
||||
*/
|
||||
import type { DatabaseBackupHealth } from "@/lib/database-backup/health";
|
||||
import type { BackupPassActivity } from "@/lib/jobs/backup-pass-attempts";
|
||||
import type { BackupScheduleStatus } from "@/lib/jobs/backup-schedule-status";
|
||||
import type { OffhostBackupFreshness } from "@/lib/jobs/offhost-backup-freshness";
|
||||
@@ -101,6 +102,12 @@ export interface BackupsList {
|
||||
* the operator's bucket, and those two fail independently.
|
||||
*/
|
||||
offhost: OffhostBackupOverview;
|
||||
/**
|
||||
* The nightly whole-database dump, the copy that rebuilds a lost server:
|
||||
* the newest good dump (kept here, off-host, or both), the newest failed
|
||||
* run, and whether this server can keep dumps at all.
|
||||
*/
|
||||
database: DatabaseBackupHealth;
|
||||
/**
|
||||
* Soft retention hint — the worker is configured for weekly backups
|
||||
* (see `DATA_BACKUP_CRON` in `src/lib/jobs/reminder-worker.ts`), and
|
||||
|
||||
Reference in new issue
Block a user