k8s-deployment/charts/roles/templates/rolebindings.yaml
2024-10-10 07:25:16 +02:00

28 lines
633 B
YAML

{{- if .Values.bindings }}
{{- range $bindings := .Values.bindings }}
---
apiVersion: rbac.authorization.k8s.io/v1
kind: {{ $bindings.kind }}
metadata:
name: {{ $bindings.name }}
namespace: {{ $bindings.namespace }}
labels:
{{- include "roles.labels" $ | nindent 4 }}
{{- with $bindings.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with $bindings.annotations}}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
subjects:
{{- with $bindings.subjects }}
{{- toYaml . | nindent 4 }}
{{- end }}
roleRef:
{{- with $bindings.roleRef }}
{{- toYaml . | nindent 2 }}
{{- end }}
{{- end }}
{{- end }}