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

Include <resource>/finalizers permission in default scaffold #1654

Closed
joelanford opened this issue Aug 27, 2020 · 1 comment · Fixed by #1688
Closed

Include <resource>/finalizers permission in default scaffold #1654

joelanford opened this issue Aug 27, 2020 · 1 comment · Fixed by #1688
Assignees
Labels
kind/feature Categorizes issue or PR as related to a new feature.

Comments

@joelanford
Copy link
Member

When deploying operators to clusters that have the OwnerReferencesPermissionEnforcement admission controller enabled, I want my operator to work without having to figure out why I get an error like this:

"deployments.apps \"memcached-sample\" is forbidden: cannot set blockOwnerDeletion if an ownerReference refers to a resource you can't set finalizers on: , <nil>"

I think this could be solved by including the following in the default controller scaffold:

// +kubebuilder:rbac:groups=<group>.<domain>,resources=<resource>/finalizers,verbs=get;update;patch

/kind feature

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
2 participants