Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove associated Velero Backups after BSL removal #162

Closed
wants to merge 1 commit into from

Conversation

mpryc
Copy link
Collaborator

@mpryc mpryc commented Jan 31, 2025

  • adds label to the Velero Backup object from the origin NaBSL
  • cleans up the Velero Backup objects with the associated label

Why the changes were made

Removal of the Backup objects after NaBSL removal should happen from the non admin BSL reconcile.

If there are any left-overs GC should take action, so the GC controller should be independent of this logic.

Responsibility to clean up Non Admin Backups when the Velero Backups objects are removed is GC.

How to test the changes made

  1. Create NaBSL
  2. Associate the Backup with the NaBSL
  3. Remove the NaBSL
  4. Ensure the Velero Backup is deleted

Copy link

openshift-ci bot commented Jan 31, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mpryc

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@mpryc mpryc mentioned this pull request Jan 31, 2025
 - adds label to the Velero Backup object from the origin NaBSL
 - cleans up the Velero Backup objects with the associated label

Signed-off-by: Michal Pryc <[email protected]>
@mpryc mpryc force-pushed the delete_velero_backup_nabsl branch from 5e6e206 to 04e9f0d Compare January 31, 2025 09:33
@mpryc
Copy link
Collaborator Author

mpryc commented Jan 31, 2025

After looking how this works, I think this PR is wrong.

The NaBSL removal should trigger Non Admin Backup removals and not the Velero Backup removals.

Then Non Admin Backup controller responsibility is to remove the Velero Backup from the openshift-adp namespace.

@mpryc
Copy link
Collaborator Author

mpryc commented Jan 31, 2025

/hold

@mpryc
Copy link
Collaborator Author

mpryc commented Jan 31, 2025

Closing as the implementation in the #163 is used.

@mpryc mpryc closed this Jan 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant