-
Notifications
You must be signed in to change notification settings - Fork 45
Bug 1898045: redeploy CSI Controller Deployment when secret changes #104
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 1898045: redeploy CSI Controller Deployment when secret changes #104
Conversation
ca93407 to
1266a18
Compare
fcec43c to
24d31b9
Compare
|
@bertinatto: This pull request references Bugzilla bug 1898045, 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
DetailsIn 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. |
|
/hold openshift/library-go#968 needs to be merged first. |
|
@bertinatto: This pull request references Bugzilla bug 1898045, which is valid. 3 validation(s) were run on this bug
DetailsIn 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. |
1 similar comment
|
@bertinatto: This pull request references Bugzilla bug 1898045, which is valid. 3 validation(s) were run on this bug
DetailsIn 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. |
24d31b9 to
d4e1a79
Compare
bd44b5e to
b1a5e9a
Compare
|
@bertinatto: This pull request references Bugzilla bug 1898045, which is valid. 3 validation(s) were run on this bug
DetailsIn 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. |
|
/hold cancel |
|
/assign @jsafrane |
b1a5e9a to
0c197b3
Compare
pkg/operator/starter.go
Outdated
|
|
||
| func withSecretHashAnnotation(kubeClient kubeclient.Interface, namespace, secret string) func(*appsv1.Deployment) error { | ||
| return func(deployment *appsv1.Deployment) error { | ||
| inputHashes, err := resourcehash.MultipleObjectHashStringMapForObjectReferences( |
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.
Would it be possible to use a secret informer? MultipleObjectHashStringMapForObjectReferenceFromLister with an informer/lister from kubeInformersForNamespaces.
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.
Good catch. Done.
Once the secret changes, the annotation changes too, which causes the Controller to be re-deployed.
0c197b3 to
3dc3ed2
Compare
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: bertinatto, jsafrane The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
@bertinatto: All pull requests linked via external trackers have merged: Bugzilla bug 1898045 has been moved to the MODIFIED state. DetailsIn 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. |
|
I manually tested the last changes and they worked. |
This PR uses changes from openshift/library-go#968 to redeploy the Controller Deployment when the secret changes.
CC @openshift/storage