Skip to content

Commit

Permalink
fix (DynamicRoleBinding): Add permissions to treat ClusterRoleBinding…
Browse files Browse the repository at this point in the history
…s to the controller
  • Loading branch information
achetronic committed Aug 9, 2024
1 parent 159f8f5 commit 38a2d0d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions config/rbac/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,8 @@ rules:
- apiGroups:
- rbac.authorization.k8s.io
resources:
- clusterroles
- clusterrolebindings
- rolebindings
verbs:
- bind
- create
Expand All @@ -94,7 +95,7 @@ rules:
- apiGroups:
- rbac.authorization.k8s.io
resources:
- rolebindings
- clusterroles
verbs:
- bind
- create
Expand Down
2 changes: 1 addition & 1 deletion internal/controller/dynamicrolebinding_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ type DynamicRoleBindingReconciler struct {
// +kubebuilder:rbac:groups=kuberbac.prosimcorp.com,resources=dynamicrolebindings,verbs=get;list;watch;create;update;patch;delete
// +kubebuilder:rbac:groups=kuberbac.prosimcorp.com,resources=dynamicrolebindings/status,verbs=get;update;patch
// +kubebuilder:rbac:groups=kuberbac.prosimcorp.com,resources=dynamicrolebindings/finalizers,verbs=update
// +kubebuilder:rbac:groups="rbac.authorization.k8s.io",resources=rolebindings,verbs=get;list;watch;create;update;patch;delete;bind;escalate
// +kubebuilder:rbac:groups="rbac.authorization.k8s.io",resources=rolebindings;clusterrolebindings,verbs=get;list;watch;create;update;patch;delete;bind;escalate
// +kubebuilder:rbac:groups="",resources=serviceaccounts,verbs=get;list
// +kubebuilder:rbac:groups="",resources=namespaces,verbs=get;list

Expand Down

0 comments on commit 38a2d0d

Please sign in to comment.