Docs Database backups

Database backups

Add storage

Backups go to any S3-compatible storage: Amazon S3, Cloudflare R2, Backblaze B2, Wasabi or MinIO on another server. Under Storages, add the endpoint, bucket, region and an access key that can write to that bucket. Dekota tests the connection before saving.

Schedule backups

  1. Open the database and choose Backups.
  2. Choose Add schedule. Use a preset such as daily or enter a cron line, for example 0 2 * * * for 02:00 every day.
  3. Turn on Save to S3 and pick the storage.
  4. Set how many backups to keep, locally and in the bucket.

Each run appears in the list with its size, how long it took and whether it worked. A failed backup sends an alert to your notification channels.

Back up now

Before a risky change, such as a migration, choose Back up now and wait for it to finish.

Restore

Restoring is an import. Choose Download next to a backup in the list to get the file, then open the database you want to fill and choose Import backup. Dekota runs the database's own restore tool, such as pg_restore. To check a backup without touching live data, create a new database and import into that one. Importing over a database replaces its data, so take a fresh backup first.

Test your backups. Every few months, import one into a new database and check that your app can read it.