Skip to content

Commit

Permalink
Add role and rolebindings to manage cost-management operator (#5694)
Browse files Browse the repository at this point in the history
PVO11Y-4662

Co-authored-by: rrajashe <rrajashe@redhat.com>
  • Loading branch information
raks-tt and rrajashe authored Feb 28, 2025
1 parent 36538a1 commit ccc35e2
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 0 deletions.
1 change: 1 addition & 0 deletions components/cost-management/base/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ resources:
- costmanagement-metrics-operator.yaml
- costmanagement-metrics-config.yaml
- external-service-account-secret.yaml
- rbac

commonAnnotations:
argocd.argoproj.io/sync-options: SkipDryRunOnMissingResource=true
24 changes: 24 additions & 0 deletions components/cost-management/base/rbac/cost-management-admin.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: cost-management-access
namespace: costmanagement-metrics-operator
rules:
- apiGroups: [""]
resources: ["*"]
verbs: ["*"]
---

apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: cost-management-access
namespace: openshift-logging
subjects:
- apiGroup: rbac.authorization.k8s.io
kind: Group
name: konflux-cost-management-admins
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: cost-management-access
4 changes: 4 additions & 0 deletions components/cost-management/base/rbac/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- cost-management-admin.yaml

0 comments on commit ccc35e2

Please sign in to comment.