add matterbridge configuration to backups

This commit is contained in:
Daniel Micay 2023-12-07 08:41:08 -05:00
parent c5c056834d
commit ae3f52087e
2 changed files with 2 additions and 0 deletions

View File

@ -10,6 +10,7 @@ ssh $remote "mkdir local-backup"
ssh $remote "mkdir local-backup/$timestamp"
ssh $remote "pg_dumpall -U postgres > local-backup/$timestamp/all_databases.sql"
ssh $remote "cp -r /etc/matterbridge.toml local-backup/$timestamp/matterbridge.toml"
ssh $remote "cp -r /etc/synapse local-backup/$timestamp/synapse"
ssh $remote "cp -r /var/lib/mjolnir local-backup/$timestamp/mjolnir"
ssh $remote "tar -cC local-backup $timestamp | zstd -9 | age -r \$(cat backup-public-key.txt) -o local-backup/$timestamp.tar.zst.age"

View File

@ -8,6 +8,7 @@ mkdir remote-backup
mkdir remote-backup/$timestamp
pg_dumpall -U postgres > remote-backup/$timestamp/all_databases.sql
cp -r /etc/matterbridge.toml remote-backup/$timestamp/matterbridge.toml
cp -r /etc/synapse remote-backup/$timestamp/synapse
cp -r /var/lib/mjolnir remote-backup/$timestamp/mjolnir
tar -cC remote-backup $timestamp | zstd -9 | age -r $(cat backup-public-key.txt) -o remote-backup/$timestamp.tar.zst.age