Controllers were unable to manage finalizers on ArgoCDRole and ArgoCDRoleBinding resources due to missing subresource support in the CRDs, resulting e.g. in the following error:
error when adding finalizer: argocdrolebindings.rb sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler
Solution
Updated the ArgoCDRole and ArgoCDRoleBinding CRDs to include finalizers as a subresource, allowing more granular RBAC permissions to manage finalizers without requiring full update access on the main resources.
Problem
Controllers were unable to manage finalizers on
ArgoCDRole
andArgoCDRoleBinding
resources due to missing subresource support in the CRDs, resulting e.g. in the following error:Solution
Updated the
ArgoCDRole
andArgoCDRoleBinding
CRDs to includefinalizers
as a subresource, allowing more granular RBAC permissions to manage finalizers without requiring full update access on the main resources.