diff --git a/config.example.sh b/config.example.sh index 88e013b..d408fb1 100644 --- a/config.example.sh +++ b/config.example.sh @@ -10,6 +10,8 @@ declare -A STORAGE_ALERT # storage in GiB STORAGE_ALERT=(["/"]=5) +BACKUP_DIRECTORY="/home/ubuntu/data" + # when set to 0, all backups are kept PRUNE_DOWN_TO=0 diff --git a/crons/backup-log.sh b/crons/backup-log.sh new file mode 100755 index 0000000..a138f68 --- /dev/null +++ b/crons/backup-log.sh @@ -0,0 +1,16 @@ +#!/bin/bash + +LOCATION=`dirname "$0"` + +source "${LOCATION}/../config.sh" + +cd "${BACKUP_DIRECTORY}" + +backups=`find * -type f | xargs du -h` +echo "${backups}" +${LOCATION}/../discord.sh general "${backups}" + +hashes=`find * -type f | xargs md5sum` +echo "${hashes}" +${LOCATION}/../discord.sh general "${hashes}" +