Problem/Motivation

When using a Flysystem FTP Destination for a scheduled backup, the number of backups to keep is ignored and the backups stack up without being deleted.

Steps to reproduce

Backup and Migrate 5.0.1
Backup and Migrate: Flysystem 5.0.0-alpha2
Flysystem 2.0.0-beta1

Create a Backup Destination to FTP Flysystem
Create a Backup Schedule with the setting 'keep 3 backups'
Allow schedule to run more than 3 times
FTP directory contains all backups rather than the 3 most recent

Using the same Schedule settings with a local destination works, and only the 3 most recent backups are kept.

Also, I noticed that when I look on the FTP server there are only .mysql.gz files in the destination folder whereas locally I can see both .mysql.gz and .mysql.gz.info files.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

rachelf created an issue. See original summary.

devad’s picture

When using a Flysystem FTP Destination for a scheduled backup, the number of backups to keep is ignored and the backups stack up without being deleted.

I can confirm this.

Also, I noticed that when I look on the FTP server there are only .mysql.gz files in the destination folder whereas locally I can see both .mysql.gz and .mysql.gz.info files.

Confirming as well.

devad’s picture

Version: 5.0.0-alpha2 » 5.0.x-dev

JonMcL made their first commit to this issue’s fork.

jonmcl’s picture

Status: Active » Needs review

I believe this is fixed. Please review with patch
https://git.drupalcode.org/project/backup_migrate_flysystem/-/merge_requ...

devad’s picture

Status: Needs review » Reviewed & tested by the community

Thanks @JonMcL. The patch #6 works nicely for me. Deleting the old FTP backups now works as expected and the .mysql.gz.info files are added to the FTP backups as well.

RTBC. The commit and a new alpha release would be nice.

  • JonMcL committed ed518aa on 5.0.x
    Issue #3228476: Number of backups to keep in schedule settings not...
jonmcl’s picture

Version: 5.0.x-dev » 5.0.0-beta1
Status: Reviewed & tested by the community » Fixed
jonmcl’s picture

Status: Fixed » Closed (fixed)