Created
March 6, 2018 20:56
-
-
Save abingham/74e2ad6a666673585c7de34a521cad83 to your computer and use it in GitHub Desktop.
Duplicity backup script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This does a simple local-to-local duplicity backup with no encryption. It keeps backups for a year. | |
export LOGFILE=<path to log file> | |
export SOURCE=<path to source directory> | |
export DEST=<path to destination directory> | |
# Without this, duplicity gets upset. | |
ulimit -n 1024 | |
date >> $LOGFILE | |
/usr/local/bin/duplicity remove-older-than 1Y file://"$SOURCE" >> $LOGFILE | |
/usr/local/bin/duplicity -v notice --allow-source-mismatch --no-encryption "$SOURCE" file://"$DEST" >> $LOGFILE |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment