Backup — Runbooks
Scheduled backups, restore procedures and disaster recovery.
Scheduled backups (cron)
# Daily at 3 AM
0 3 * * * cd /opt/aetheris && docker compose exec -T postgres pg_dump --username=aetheris --dbname=aetheris --format=custom > /backups/aetheris-$(date +\%F).dumpRestore procedure
1. Stop the web app
docker compose stop web worker2. Restore the database
cat backup.dump | docker compose exec -T postgres pg_restore \
--username=aetheris --dbname=aetheris --clean --if-exists3. Restart
docker compose up -d4. Verify
curl -sS http://localhost:8000/health
curl -sS -o /dev/null -w '%{http_code}\n' http://localhost:3000/loginDisaster recovery
If the entire host is lost:
- Install Docker on a new machine.
- Clone
aetheris-app, restore.env. - Restore PostgreSQL from backup.
docker compose up -d --build.
What's NOT in the backup
- Docker images (re-pulled on
docker compose up --build) - Node modules (re-installed on
npm ci) - TLS certificates (re-issued by Certbot)
See also: Backup overview, Upgrades.