diff options
-rwxr-xr-x | alpine-backup | 2 | ||||
-rwxr-xr-x | profiles/backup-mysql | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/alpine-backup b/alpine-backup index 22af5a5..cf05943 100755 --- a/alpine-backup +++ b/alpine-backup @@ -9,6 +9,8 @@ else exit 1 fi +mkdir -p "$BACKUP_LOCATION" "$BACKUP_CACHE" + # set the suffix of backup files when ecryptions is enabled [ -n "$ENCRYPTION" ] && export SUFFIX=".$ENCRYPTION" diff --git a/profiles/backup-mysql b/profiles/backup-mysql index ff6edd6..3c4e232 100755 --- a/profiles/backup-mysql +++ b/profiles/backup-mysql @@ -2,7 +2,6 @@ if [ -n "$MYSQL_PASSWORD" ]; then echo "Dumping databases to: $BACKUP_CACHE/mysql.sql" - [ -d "$CACHE_DIR" ] || mkdir -p "$BACKUP_CACHE" mysqldump -u root -p${MYSQL_PASSWORD} --all-databases -r \ $BACKUP_CACHE/mysql.sql else |