-
Notifications
You must be signed in to change notification settings - Fork 71
Wrap Listener to also return dynamiclistener config #184
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Vitor Savian <[email protected]>
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.
Couple nits.
How do you envision this being called from the K3s side? You're just planning on calling listener.RegenerateCerts directly from K3s?
If you add the ability to do that directly, you might as well remove the RegenerateCerts callback that can be set in the config, but is only called once from NewListenerWithChain
Line 146 in 8fd666b
RegenerateCerts func() bool |
Lines 88 to 91 in 8fd666b
if config.RegenerateCerts != nil && config.RegenerateCerts() { | |
if err := dynamicListener.regenerateCerts(); err != nil { | |
return nil, nil, err | |
} |
Signed-off-by: Vitor Savian <[email protected]>
485cc83
to
4871e79
Compare
4871e79
to
6801649
Compare
Signed-off-by: Vitor Savian <[email protected]>
Any plans to address the duplication of function with the existing |
I thought we would have another user that used dynamic listener, but since we are the only users, I will remove that. |
Signed-off-by: Vitor Savian <[email protected]>
We are actually the only users of NewListener/NewListenerWithChain - other rancher projects all just use server.ListenAndServe |
@vitorsavian do we still need this? |
Proposed Changes
listener
configWhy
hot reload
without the need for restarton demand
is to use thelistener
that was created inNewListenerWithChain
initial setup.