restore target / is errorprone

This commit is contained in:
jem 2020-12-12 18:17:38 +01:00
parent fce672be0b
commit e0fcd1da3a
2 changed files with 2 additions and 2 deletions

View file

@ -19,7 +19,7 @@ function main() {
restic -r ${RESTIC_REPOSITORY}/db backup --stdin restic -r ${RESTIC_REPOSITORY}/db backup --stdin
# backup nextcloud filesystem # backup nextcloud filesystem
restic -r ${RESTIC_REPOSITORY}/files backup /var/backups/ cd /var/backups/ && restic -r ${RESTIC_REPOSITORY}/files backup .
} }
source /usr/local/lib/functions.sh source /usr/local/lib/functions.sh

View file

@ -13,7 +13,7 @@ function main() {
# files # files
rm -rf /var/backups/* rm -rf /var/backups/*
restic -r $RESTIC_REPOSITORY/files restore latest --target /var/backups/ restic -r $RESTIC_REPOSITORY/files restore latest --target /var/backup/
# db # db
psql -d template1 -h ${POSTGRES_SERVICE} -p ${POSTGRES_PORT} -U ${POSTGRES_USER} \ psql -d template1 -h ${POSTGRES_SERVICE} -p ${POSTGRES_PORT} -U ${POSTGRES_USER} \