Backups
The Backups page configures automated and on-demand database backups for the Config DB and Results DB. Backups can be scheduled daily, retained for a configurable number of days, encrypted at rest, and optionally replicated to S3-compatible storage.
Inputs
| Name | Description | Allowed Values | Default |
|---|---|---|---|
| Config DB Enabled | Enable scheduled backups for the configuration database | Boolean | true |
| Config DB Schedule | Hour of day (UTC) for the Config DB backup | 0-23 | 02:00 |
| Results DB Enabled | Enable scheduled backups for the results database | Boolean | true |
| Results DB Schedule | Hour of day (UTC) for the Results DB backup | 0-23 | 03:00 |
| Config DB Retention | Days to keep Config DB backups before auto-deletion | 1-365 days | 30 |
| Results DB Retention | Days to keep Results DB backups before auto-deletion | 1-365 days | 7 |
| Minimum Free Space | Backups are skipped if free disk space falls below this threshold | Bytes (positive integer) | 500 MB |
| Encryption Key | AES encryption key for backup bundles at rest | Any string or empty to disable | Empty (disabled) |
| S3 Bucket | S3-compatible bucket for off-site backup replication | Valid bucket name | Empty (disabled) |
Fields & Columns
| Name | Description |
|---|---|
| Bundle | Unique identifier for the backup bundle |
| Timestamp | When the backup was created |
| Config DB | Size of the Config DB dump in the bundle |
| Results DB | Size of the Results DB dump in the bundle |
How To
Trigger an immediate backup
- Click the "Backup Now" button in the Actions section
- Wait up to 60 seconds for the backup container to process the request
- Check the Trigger History section for the result status
Configure S3 replication
- Enable S3 and fill in the bucket, region, access key, and secret key
- Click "Test Connection" to verify S3 access
- Click "Save Configuration" to persist the settings
Restore from backup
- Navigate to Admin > Backups.
- Click the Restore tab.
- Upload the backup bundle file.
- Select the target database.
- Confirm the restore operation.
Gotchas
- The backup container polls every 60 seconds, so triggered backups are not instantaneous.
- Backups are skipped automatically when free disk space is below the configured minimum.
- S3 endpoint is only needed for non-AWS S3-compatible providers (e.g., MinIO, Backblaze B2).
- Restore is available via the Day 0 Setup Wizard (GUI upload or S3 pull) or the CLI script (scripts/restore.sh). Restore endpoints at /api/setup/restore/* are only accessible before an owner exists.
- Results DB backups default to 7 days (shorter than Config DB at 30 days) because scan result dumps are significantly larger. Adjust retention based on your storage capacity and compliance requirements.
API Calls (8)
| Method | Path | Description |
|---|---|---|
| GET | /api/admin/backups/config | Retrieve current backup configuration |
| PUT | /api/admin/backups/config | Update backup configuration |
| GET | /api/admin/backups | List existing backup bundles |
| POST | /api/admin/backups/trigger | Trigger an immediate backup |
| GET | /api/admin/backups/triggers | List backup trigger history |
| POST | /api/admin/backups/test-s3 | Test S3 connection with current settings |
| GET | /api/admin/backups/:id/download | Download a backup bundle |
| POST | /api/admin/backups/generate-encryption-key | Generate a new backup encryption key (server-side crypto) |
Related Pages
- Backup Health — Shows real-time backup process status and last run result
- Settings — System-wide settings that affect backup behavior
- Maintenance — Quick-access backup trigger and S3 test without leaving the maintenance page