Databases & Storage

BackupDrill adds automated restore drills for Supabase PostgreSQL backups

Key Takeaway

BackupDrill is an open-source CLI tool that backs up Supabase PostgreSQL databases to S3-compatible storage and automatically verifies each backup by restoring it into a temporary container.

Summary

BackupDrill addresses a common operational failure: backups that were never tested and fail during actual recovery. The tool runs pg_dump against Supabase-hosted PostgreSQL 15-17 databases, streams the archive to any S3-compatible bucket with a checksummed manifest, then performs automated restore drills. The drill verifies archive integrity, pg_restore completion, presence of indexes, constraints, triggers, and non-empty data tables. The MIT-licensed CLI is available via npm and GitHub; a hosted service with scheduling and email alerts offers a free tier.

How BackupDrill verifies backups

  • Uses pg_dump custom format against Supabase projects, streaming to S3-compatible buckets (AWS S3, Cloudflare R2, Backblaze B2, Wasabi)
  • Generates a checksummed manifest; storage files can be included in the same snapshot
  • backupdrill drill command restores the latest snapshot into a throwaway PostgreSQL container using pg_restore
  • Validates: archive checksum, pg_restore exit status, post-data objects (indexes, constraints, triggers), table presence, and non-empty data tables
  • Records restore duration for operational metrics
  • Enforces pg_dump major version ≥ server version; refuses older clients
  • Produces plain pg_dump archives compatible with stock pg_restore without BackupDrill

Why it matters

For teams relying on Supabase, BackupDrill closes the gap between "having backups" and "having verified recoverable backups," a common source of production outages. The open-source CLI and free hosted tier lower the barrier for smaller projects to adopt backup verification practices previously requiring custom infrastructure.

Original reference: www.postgresql.org →