You can expire the backup in two ways:
- Manual expiration: Utilize the following command to manually expire a backup
kubectl patch backup <backup_name> --type='json' -p='[{"op": "replace", "path": "/spec/expire", "value": true}]'
- Retention policy: Based on the backup retention policy, the operator deletes both the backup CR and its associated data if any of the following policies are satisfied.
- numberOfDaysToKeep: Define the number of days for which backups should be retained.
- successfulBackupsToKeep: Specify the number of successful backups to retain.
- failedBackupsToKeep: Indicate the number of failed backups to retain.