Skip to content

Add permission to manage aggregated clusterroles #76

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

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions bundle/manifests/shipwright-operator.clusterserviceversion.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -514,6 +514,26 @@ spec:
- get
- list
- watch
- apiGroups:
- rbac.authorization.k8s.io
resourceNames:
- shipwright-build-aggregate-edit
resources:
- clusterroles
verbs:
- delete
- patch
- update
- apiGroups:
- rbac.authorization.k8s.io
resourceNames:
- shipwright-build-aggregate-view
resources:
- clusterroles
verbs:
- delete
- patch
- update
- apiGroups:
- rbac.authorization.k8s.io
resourceNames:
Expand Down
20 changes: 20 additions & 0 deletions config/rbac/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,26 @@ rules:
- get
- list
- watch
- apiGroups:
- rbac.authorization.k8s.io
resourceNames:
- shipwright-build-aggregate-edit
resources:
- clusterroles
verbs:
- delete
- patch
- update
- apiGroups:
- rbac.authorization.k8s.io
resourceNames:
- shipwright-build-aggregate-view
resources:
- clusterroles
verbs:
- delete
- patch
- update
- apiGroups:
- rbac.authorization.k8s.io
resourceNames:
Expand Down
2 changes: 2 additions & 0 deletions controllers/shipwrightbuild_rbac.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ package controllers
// +kubebuilder:rbac:groups=apiextensions.k8s.io,resources=customresourcedefinitions,verbs=get;list;watch;create
// +kubebuilder:rbac:groups=apiextensions.k8s.io,resources=customresourcedefinitions,resourceNames=builds.shipwright.io;buildruns.shipwright.io;buildstrategies.shipwright.io;clusterbuildstrategies.shipwright.io,verbs=update;patch;delete
// +kubebuilder:rbac:groups=rbac.authorization.k8s.io,resources=clusterroles,verbs=get;list;watch;create
// +kubebuilder:rbac:groups=rbac.authorization.k8s.io,resources=clusterroles,resourceNames=shipwright-build-aggregate-edit,verbs=update;patch;delete
// +kubebuilder:rbac:groups=rbac.authorization.k8s.io,resources=clusterroles,resourceNames=shipwright-build-aggregate-view,verbs=update;patch;delete
// +kubebuilder:rbac:groups=rbac.authorization.k8s.io,resources=clusterroles,resourceNames=shipwright-build-controller,verbs=update;patch;delete
// +kubebuilder:rbac:groups=rbac.authorization.k8s.io,resources=clusterrolebindings,verbs=get;list;watch;create
// +kubebuilder:rbac:groups=rbac.authorization.k8s.io,resources=clusterrolebindings,resourceNames=shipwright-build-controller,verbs=update;patch;delete
Expand Down