Add Backup Bot Two support #27

Open
ChasquiLabo wants to merge 1 commits from escuela-comun/peertube:add-backup-support into main
First-time contributor

Summary

Adds backup and restore support for PeerTube using Backup Bot Two and the CoopCloud backup specification.

PostgreSQL is backed up using pg_dump instead of copying the live database volume.

Changes

  • Enable Backup Bot Two support.
  • Back up persistent PeerTube data and configuration.
  • Exclude temporary, cache, and live database volumes.
  • Add a PostgreSQL helper service for backup and restore hooks.
  • Clean up temporary database dumps after backups and successful restores.

Why an additional backup service?

The current PostgreSQL image (pgautoupgrade:18-alpine) does not include Bash, which Backup Bot Two requires to execute hooks. A lightweight postgres:18-trixie helper service allows pg_dump and pg_restore to run without modifying the existing database image.

Testing

Tested with PeerTube 8.3.2 and PostgreSQL 18.

  • Successfully created and verified a Restic snapshot.
  • Restored the PostgreSQL dump into an isolated database (76 tables).
  • Removed the PeerTube stack and all eight volumes.
  • Redeployed PeerTube and successfully restored it using Backup Bot Two.
  • Verified that the original user and published video were recovered.
  • Confirmed automatic cleanup of the temporary database dump after restoration.

AI Assistance

Developed with assistance from ChatGPT (OpenAI LLM), with backup and full restoration tested in a real CoopCloud environment.

Summary Adds backup and restore support for PeerTube using Backup Bot Two and the CoopCloud backup specification. PostgreSQL is backed up using `pg_dump` instead of copying the live database volume. Changes - Enable Backup Bot Two support. - Back up persistent PeerTube data and configuration. - Exclude temporary, cache, and live database volumes. - Add a PostgreSQL helper service for backup and restore hooks. - Clean up temporary database dumps after backups and successful restores. Why an additional backup service? The current PostgreSQL image (`pgautoupgrade:18-alpine`) does not include Bash, which Backup Bot Two requires to execute hooks. A lightweight `postgres:18-trixie` helper service allows `pg_dump` and `pg_restore` to run without modifying the existing database image. Testing Tested with PeerTube 8.3.2 and PostgreSQL 18. - Successfully created and verified a Restic snapshot. - Restored the PostgreSQL dump into an isolated database (76 tables). - Removed the PeerTube stack and all eight volumes. - Redeployed PeerTube and successfully restored it using Backup Bot Two. - Verified that the original user and published video were recovered. - Confirmed automatic cleanup of the temporary database dump after restoration. AI Assistance Developed with assistance from ChatGPT (OpenAI LLM), with backup and full restoration tested in a real CoopCloud environment.
ChasquiLabo added 1 commit 2026-11-11 01:03:15 +00:00
Add Backup Bot Two support for PeerTube
continuous-integration/drone/pr Build is failing
416f9a0b48
Some required checks failed
continuous-integration/drone/pr Build is failing
You are not authorized to merge this pull request.
This pull request can be merged automatically.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u https://git.coopcloud.tech/escuela-comun/peertube add-backup-support:escuela-comun-add-backup-support
git checkout escuela-comun-add-backup-support
Sign in to join this conversation.