Fix permissions for endpointslice controller#89741
Fix permissions for endpointslice controller#89741k8s-ci-robot merged 1 commit intokubernetes:masterfrom
Conversation
The controller needs to be able to set a service's finalizers to be able to create an EndpointSlice resource that is owned by the service and sets blockOwnerDeletion=true in its ownerRef.
thockin
left a comment
There was a problem hiding this comment.
I don't know much about how blockOwnerDeletion is implemented - is that synchronous to the original REST call?
This seems OK, so I will approve, but Rob needs to LGTM
/approve
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: marun, thockin 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 |
|
@thockin I've been talking with @marun on Slack about this PR, and agree that it's a good fix. This was not noticed in k/k because we do not enable the /lgtm |
|
I've updated the PR description to reflect the involvement of the |
|
/sig network |
|
/retest |
…upstream-release-1.18 Automated cherry pick of #89741: Fix permissions for endpointslice controller
…upstream-release-1.17 Automated cherry pick of #89741: Fix permissions for endpointslice controller
What type of PR is this?
/kind bug
What this PR does / why we need it:
When the
OwnerReferencesPermissionEnforcementvalidating admission plugin is enabled, the EndpointSlice controller needs permission to update a service's finalizers to be able to create an EndpointSlice resource that is owned by the service and sets blockOwnerDeletion=true in its ownerRef.The lack of this permission breaks the EndpointSlice controller on openshift, which enables
OwnerReferencesPermissionEnforcementby default. The problem isn't apparent on kube due toOwnerReferencesPermissionEnforcementbeing disabled by default.