testing restic scripts
This commit is contained in:
31
restic/restic-sftp/restic-sftp-backup.sh
Normal file
31
restic/restic-sftp/restic-sftp-backup.sh
Normal file
@@ -0,0 +1,31 @@
|
||||
#!/bin/bash
|
||||
|
||||
export RESTIC_PASSWORD="8ung1e1!"
|
||||
|
||||
# backup /home/akanealw
|
||||
export RESTIC_REPOSITORY="sftp:akanealw@truenas:/mnt/data/backups/resticbackups/changemepls/home/akanealw"
|
||||
restic unlock
|
||||
restic backup /home/akanealw --no-cache -v
|
||||
restic unlock
|
||||
restic forget --keep-last 25 --prune
|
||||
|
||||
# backup /etc
|
||||
export RESTIC_REPOSITORY="sftp:akanealw@truenas:/mnt/data/backups/resticbackups/changemepls/etc"
|
||||
restic unlock
|
||||
restic backup /etc --no-cache -v
|
||||
restic unlock
|
||||
restic forget --keep-last 25 --prune
|
||||
|
||||
# backup /opt
|
||||
export RESTIC_REPOSITORY="sftp:akanealw@truenas:/mnt/data/backups/resticbackups/changemepls/opt"
|
||||
restic unlock
|
||||
restic backup /opt --no-cache -v
|
||||
restic unlock
|
||||
restic forget --keep-last 25 --prune
|
||||
|
||||
# backup /root
|
||||
export RESTIC_REPOSITORY="sftp:akanealw@truenas:/mnt/data/backups/resticbackups/changemepls/root"
|
||||
restic unlock
|
||||
restic backup /root --no-cache -v
|
||||
restic unlock
|
||||
restic forget --keep-last 25 --prune
|
||||
Reference in New Issue
Block a user