Restore databases and mailboxes from local account backups #36

Merged
parkel merged 4 commits from feature/account-backup-recovery into main 2026-11-21 14:56:59 +01:00
Owner

Summary

  • Restore a selected MariaDB database or mailbox from a completed local account backup. The selector lists resources present in the archive and still assigned to the account.
  • Reuse the native database and mailbox recovery commands. A database must be empty, and a mailbox must have no Maildir. Publish a restored Maildir without replacing a directory created during recovery.
  • Show website, database, and mailbox requests in one history with source, target, operator, and result. Keep separate operator permissions and deployment switches for each restore type.
  • Run recovery through the existing backup worker and restore socket. Persist receipts to prevent duplicate deliveries from applying a restore twice.
  • Document the socket drop-ins, including the website drop-in for deployments upgrading the previous website-only service.

Verification

  • Ruff lint and format checks, Django migration drift check, and all 316 Django tests passed.
  • Ubuntu with MariaDB, Postfix, Dovecot, and Celery restored a website, a database dump, and a mailbox. Non-empty database and mailbox targets were preserved. Replaying the database restore preserved rows written after recovery.
  • Static systemd verification passed for the restore service, socket, and worker drop-ins.
## Summary - Restore a selected MariaDB database or mailbox from a completed local account backup. The selector lists resources present in the archive and still assigned to the account. - Reuse the native database and mailbox recovery commands. A database must be empty, and a mailbox must have no Maildir. Publish a restored Maildir without replacing a directory created during recovery. - Show website, database, and mailbox requests in one history with source, target, operator, and result. Keep separate operator permissions and deployment switches for each restore type. - Run recovery through the existing backup worker and restore socket. Persist receipts to prevent duplicate deliveries from applying a restore twice. - Document the socket drop-ins, including the website drop-in for deployments upgrading the previous website-only service. ## Verification - Ruff lint and format checks, Django migration drift check, and all 316 Django tests passed. - Ubuntu with MariaDB, Postfix, Dovecot, and Celery restored a website, a database dump, and a mailbox. Non-empty database and mailbox targets were preserved. Replaying the database restore preserved rows written after recovery. - Static systemd verification passed for the restore service, socket, and worker drop-ins.
parkel added 4 commits 2026-11-21 14:55:24 +01:00
parkel merged commit d088a487a3 into main 2026-11-21 14:56:59 +01:00
parkel deleted branch feature/account-backup-recovery 2026-11-21 14:56:59 +01:00
Sign in to join this conversation.