Skip to content

Commit

Permalink
Bugfix: Use automatically_remove_old config option when deciding to p…
Browse files Browse the repository at this point in the history
…rune or not
  • Loading branch information
erkie committed Jan 28, 2019
1 parent 36bc1a9 commit 2546897
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/backup_perform.go
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ func backupMysqlPerform(backupType string, backupsBucket string, mysqlDataPath s
}

// Success! Now we can consider removing old backups
if backupType == backupTypeFull {
if backupType == backupTypeFull && configStruct.Retention != nil && configStruct.Retention.AutomaticallyRemoveOld {
allBackups, backupErr := listAllBackups(hostname, backupsBucket, minioClient)
if backupErr != nil {
pkg.AlertError(configStruct.Alerting, "Backup completed, but could not perform pruning. Failed on listing backups.", err)
Expand Down

0 comments on commit 2546897

Please sign in to comment.