modmapper/scripts/backup.sh

7 lines
335 B
Bash
Raw Normal View History

#!/bin/bash
export $(grep -v '^#' .env | xargs -d '\n')
mkdir -p backups
zip -r -9 backups/plugins.zip plugins -DF --out backups/plugins-update.zip
2022-02-13 04:26:45 +00:00
pg_dump -h localhost -U modmapper -Fc modmapper > backups/modmapper-$(date +'%Y-%m-%d').dump
find backups/modmapper-*.dump -mtime +30 -type f -delete
2022-02-13 19:34:09 +00:00
rclone sync backups dropbox:modmapper