Skip to content

Commit

Permalink
feat(helm): more roles
Browse files Browse the repository at this point in the history
Signed-off-by: Hy3n4 <[email protected]>
  • Loading branch information
Hy3n4 committed Nov 6, 2023
1 parent 32cdd30 commit 30e00ff
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 2 deletions.
1 change: 0 additions & 1 deletion helm/osko/templates/cluster-role.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
Expand Down
1 change: 0 additions & 1 deletion helm/osko/templates/leader_election_role.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# permissions to do leader election.
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
Expand Down
14 changes: 14 additions & 0 deletions helm/osko/templates/prometheusrule_editor_role.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
labels:
{{ include "osko.labels" . | nindent 4 }}
name: prometheus-rule-editor-rolebinding
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ .Release.Name }}-prometheusrule-editor-role
subjects:
- kind: ServiceAccount
name: {{ include "osko.fullname" . }}
namespace: {{ .Release.Namespace }}
20 changes: 20 additions & 0 deletions helm/osko/templates/prometheusrule_editor_role_binding.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
labels:
{{ include "osko.labels" . | nindent 4 }}
name: {{ .Release.Name }}-prometheusrule-editor-role
rules:
- apiGroups:
- monitoring.coreos.com
resources:
- prometheusrules
verbs:
- get
- list
- watch
- create
- update
- patch
- delete

0 comments on commit 30e00ff

Please sign in to comment.