-
Notifications
You must be signed in to change notification settings - Fork 20
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
Bug 2267885: Add hub recovery labels for backing up secrets #194
Bug 2267885: Add hub recovery labels for backing up secrets #194
Conversation
@vbnrh: No Bugzilla bug is referenced in the title of this pull request. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
@vbnrh: This pull request references Bugzilla bug 2267885, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker. 3 validation(s) were run on this bug
Requesting review from QA contact: In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
@openshift-ci[bot]: GitHub didn't allow me to request PR reviews from the following users: keesturam. Note that only red-hat-storage members and repo collaborators can review this PR, and authors cannot review their own PRs. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
58bc0fb
to
76fb4c7
Compare
@@ -97,6 +100,7 @@ func generateBlueSecretForExternal(rookCephMon *corev1.Secret, labelType utils.S | |||
Namespace: managedClusterName, | |||
Labels: map[string]string{ | |||
utils.SecretLabelTypeKey: string(labelType), | |||
HubRecoveryLabel: "", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it not HubRecoveryLabel: "resource" ?
i can see it is used like that: https://github.com/red-hat-storage/odf-multicluster-orchestrator/pull/194/files#diff-71a31664c2a326d791c6040801a670cc01383300df3e4378f843bb619d2ea4e8R163
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The value for the resource is not necessary
Backup secrets and ConfigMaps with one of the following labels: cluster.open-cluster-management.io/type, hive.openshift.io/secret-type, cluster.open-cluster-management.io/backup.
MirrorPeer has it as earlier documentations indicated the value to be a generic resource
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logger := log.FromContext(ctx, "controller", "MirrorPeerSecret") | ||
logger.Info("Adding backup labels to the secret") | ||
_, err := controllerutil.CreateOrUpdate(ctx, rc, &peerSecret, func() error { | ||
peerSecret.ObjectMeta.Labels[utils.HubRecoveryLabel] = "" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3cce4f3
to
f8fe0ef
Compare
This commit adds label changes for source secrets (blue) and s3 secrets for hub recovery Signed-off-by: vbadrina <[email protected]>
Adds label changes to managedcluster agent where they will add hub recovery label by default onto any source secret Signed-off-by: vbadrina <[email protected]>
f8fe0ef
to
069ed23
Compare
@GowthamShanmugam: changing LGTM is restricted to collaborators In response to this: Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: GowthamShanmugam, vbnrh 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 |
/LGTM |
@GowthamShanmugam: changing LGTM is restricted to collaborators In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
046d749
into
red-hat-storage:release-4.15
@vbnrh: All pull requests linked via external trackers have merged: Bugzilla bug 2267885 has been moved to the MODIFIED state. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
These commits add label changes to the generated source secret as well as the ones present on the hub to make them a candidate for ACM backup and restore (https://access.redhat.com/documentation/en-us/red_hat_advanced_cluster_management_for_kubernetes/2.6/html-single/backup_and_restore)
This is done as a fix to hub recovery issue where secrets are not generated due when both the active hub and primary cluster being co-situated on the same site or zone. This causes the VRC to not be created on the remaining managed clusters and failover fails.