support label selector in MutatingWebhook #76697
Labels
kind/feature
Categorizes issue or PR as related to a new feature.
sig/api-machinery
Categorizes an issue or PR as relevant to SIG API Machinery.
What would you like to be added:
In webbook, I would like to add a
labelSelector
to filter which object should be called with webhook, just like namespaceSelectorWhy is this needed:
In istio, we use
MutatingWebhook
to inject sidecar into pod. For now, webhook only supportsnamespaceSelector
, so when the namespace match, all pods in the namespace will call webhook to check if inject is necessary. In the real world, not all pods in the namespace needs inject. And in some bad case, when the webhook service goes down, it will affect the pods which have no need to inject. So I suggest adding alabelSelector
.The text was updated successfully, but these errors were encountered: