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

apiserver/admission-webhooks: make lcluster aware #60

Conversation

sttts
Copy link
Member

@sttts sttts commented Apr 27, 2022

Credit to #52 by @shawn-hurley. I have just simplified it a little to make it less costly on rebases.

Add ability to handle validating and mutating webhooks for logical cluster
Attempted to keep the changes localized to admission plugin package
@@ -115,9 +113,6 @@ func NewServerRunOptions() *ServerRunOptions {
// disable the watch cache
s.Etcd.EnableWatchCache = false

// TODO: turn off the admission webhooks for now
s.Admission.DefaultOffPlugins.Insert(validating.PluginName, mutating.PluginName)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@shawn-hurley I remove you insert few lines below. Is that correct? Any reason it should be off by default?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They should be off by default for us because they are not logical cluster-aware. For the generic control plane, I think it could be fine, but we will need to double-check in the KCP pr that this is off.

Copy link

@shawn-hurley shawn-hurley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I really think the wrapper is a good idea! +1 on the change will close mine if not already closed

@sttts sttts force-pushed the sttts-add-validation-admission-lcluster-aware branch from 228aa3f to cc7ed2e Compare April 27, 2022 16:12
It breaks current kcp main. We will reapply when kcp is updated.

This reverts commit bdc8872.
@sttts sttts merged commit c8eb467 into kcp-dev:feature-logical-clusters-1.23 Apr 27, 2022
@sttts sttts deleted the sttts-add-validation-admission-lcluster-aware branch April 27, 2022 17:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants