Skip to content

Commit

Permalink
bugfix: rbac role
Browse files Browse the repository at this point in the history
Signed-off-by: Smuu <[email protected]>
  • Loading branch information
smuu committed Aug 5, 2024
1 parent d01ad48 commit 3676aea
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 11 deletions.
9 changes: 2 additions & 7 deletions charts/celestia-node/templates/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,9 @@ metadata:
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
{{- end }}
rules:
# TODO: Update resources and verbs to the proper values for the application cases
- apiGroups: [""]
resources: ["*"]
verbs: ["*"]
- apiGroups: [""]
resources: ["*"]
verbs: ["*"]
{{- if .Values.rbac.rules }}
{{- include "common.tplvalues.render" ( dict "value" .Values.rbac.rules "context" $ ) | nindent 2 }}
{{- else }}
[]
{{- end }}
{{- end }}
Original file line number Diff line number Diff line change
@@ -1,17 +1,20 @@
kind: ClusterRoleBinding
{{ if .Values.rbac.create }}
kind: RoleBinding
apiVersion: {{ include "common.capabilities.rbac.apiVersion" . }}
metadata:
name: {{ template "common.names.fullname" . }}
name: {{ include "common.names.fullname" . }}
namespace: {{ include "common.names.namespace" . | quote }}
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
app.kubernetes.io/component: node
{{- if .Values.commonAnnotations }}
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
{{- end }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ template "common.names.fullname" . }}
kind: Role
name: {{ include "common.names.fullname" . }}
subjects:
- kind: ServiceAccount
name: {{ template "node.serviceAccountName" . }}
namespace: {{ include "common.names.namespace" . | quote }}
{{- end }}

0 comments on commit 3676aea

Please sign in to comment.