Automated local and remote backups of your Ente photo library.
- Hourly syncing via Ente CLI
- Point-in-time encrypted backups in S3 via restic (optional)
- Push notifications for backup success/errors via ntfy.sh (optional)
- Docker Compose
This is best run on a headless server with enough free storage for your photo library (e.g. I run this on a Raspberry Pi connected to a 240GB SSD). By default, syncing from Ente occurs hourly and backups to S3 happen daily at 8pm PST, but these are both configurable.
- Copy the example environment file and fill in the Ente section:
cp .env.example .env
If you want photos exported somewhere other than /data/ente-photos, set EXPORT_DIR in .env to your chosen path; make sure the directory exists on the host first (sudo mkdir -p "$EXPORT_DIR").
- Build and start the container:
docker compose up -d --build
- Perform the initial Ente login:
docker compose exec backups ente account add
You'll be prompted for your Ente email, password, and an export directory. For the export directory, enter the same value as EXPORT_DIR in .env (default /data/ente-photos); this must be a path that exists inside the container, which is what the bind mount in step 1 sets up. Anything else will fail with invalid export directory.
- Kick off the first sync to verify (otherwise it'll wait until the top of the next hour):
docker compose exec backups ente-sync
The first full sync can take hours depending on library size; you can detach the terminal with Ctrl+P, Ctrl+Q without stopping the export.
Restic creates encrypted, deduplicated backups of your photo library to an S3 bucket.
- Create an S3 bucket in AWS (or any S3-compatible provider like Backblaze B2 or Wasabi).
- Create an IAM user with read/write access to the bucket and generate an access key.
- Fill in the Restic section of
.env:
RESTIC_REPOSITORY=s3:s3.amazonaws.com/your-bucket
RESTIC_PASSWORD=your-encryption-password # used to encrypt backups; store this safely, e.g. in a password manager
AWS_ACCESS_KEY_ID=your-access-key
AWS_SECRET_ACCESS_KEY=your-secret-key
- Initialize the restic repository:
docker compose exec backups restic init
If the Restic variables are left empty, the daily backup job will skip silently.
ntfy.sh sends push notifications to your phone or desktop when syncs or backups succeed or fail.
- Install the ntfy app wherever you plan to receive notifications.
- Choose a topic name; this can be anything, but should be unique and hard to guess (e.g.
my-ente-backups-a1b2c3). - Subscribe to your topic name in the ntfy app.
- Set
NTFY_TOPICin.envto your topic name:
NTFY_TOPIC=my-ente-backups-a1b2c3
If NTFY_TOPIC is left empty, notifications are disabled.
Sync failures and timeouts trigger an immediate notification. To prevent notification fatigue, successes are batched into a daily summary sent after every 24 runs, reporting how many succeeded. Restic backups notify on both success and failure.
docker compose exec backups ente-sync: run the ente export manuallydocker compose exec backups bash /usr/local/bin/restic-backup.sh: run the restic backup manually
- Logs:
docker compose logs -f