-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Add ability to the VPA admission-controller to reload it's certificate v2 #6665
Conversation
Hi @Nuckal777. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. 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. |
/assign krzysied kwiesmueller Would appreciate a review. |
/assign @laoj2 @sophieliu15 |
@kwiesmueller: GitHub didn't allow me to assign the following users: laoj2. Note that only kubernetes members with read permissions, repo collaborators and people who have commented on this issue/PR can be assigned. Additionally, issues/PRs can only have 10 assignees at the same time. 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. |
go func() { | ||
defer watcher.Close() | ||
for { | ||
select { |
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.
Do we need to add a default case here?
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.
I think that no default case is required. A goroutine is forked off, which runs the blocking select. The channels are filled by the fsnotify implementation. Do you have a use case for a default case?
/lgtm |
I hope, I addressed everything. Did I miss something? |
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.
Generally lgtm.
Sorry for not bringing this up earlier. Do you think you can add an e2e/integration test for this feature?
Would generating a second pair of certificates in |
That sounds good to me, yes. |
Should we run |
I had some thought about regarding the self registration again. I'd like to use the VPA together with cert-manager. This means the Given the self registration would not be helpful in that setup, I think we don't need to touch it here. Any opinions? |
I'm fine with not touching the self-registration here. I also think it is unlikely that the webhook can be deployed with self-registgration if you have a mechanism which automatically renews the certificate. So this is good to go from my side. @kwiesmueller do you have any additional changes you want to see in this PR? |
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.
/lgtm
/approve
/ok-to-test |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: kwiesmueller, Nuckal777 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 |
Thanks for adding the test! |
What type of PR is this?
/kind feature
What this PR does / why we need it:
Adds the ability for the admission-controller to reload it's certificate on changes to the certificate file. This is useful when provisioning certificates with cert-manager.
Which issue(s) this PR fixes:
Fixes #6272.
Special notes for your reviewer:
Does this PR introduce a user-facing change?
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:
None.