sally docs

Recovery

This page covers the basic backup and restore model for a Sally deployment.

What gets backed up

  • PostgreSQL database dump (database.dump)
  • uploaded files from the API uploads directory (uploads.tar.gz)
  • backup manifest (manifest.txt)

Typical backup location on a VPS

  • root: /var/backups/sally
  • latest symlink: /var/backups/sally/latest

Manual backup

sudo /opt/sally/ops/backup.sh

Restore procedure

1. Stop app services

sudo systemctl stop sally-web
sudo systemctl stop sally-api

2. Restore the database

export DATABASE_URL=$(grep '^DATABASE_URL=' /opt/sally/apps/api/.env | cut -d= -f2-)
pg_restore --clean --if-exists --no-owner --no-privileges --dbname="$DATABASE_URL" /var/backups/sally/latest/database.dump

3. Restore uploads

mkdir -p /opt/sally/apps/api/uploads
rm -rf /opt/sally/apps/api/uploads/*
tar -C /opt/sally/apps/api/uploads -xzf /var/backups/sally/latest/uploads.tar.gz

4. Start services

sudo systemctl start sally-api
sudo systemctl start sally-web

5. Verify

curl -sS https://your-sally-domain.com/api/health

What to verify after a restore

  • login works
  • project list loads
  • task list loads
  • uploaded images or assets resolve correctly
  • password reset and invite mail flow still work

Notes

  • the backup script commonly keeps 14 days of backups by default
  • the system is only really recoverable if both the DB dump and uploads archive are present
  • operators should test restore procedures before they need them in production