k8s-deployment/charts/roles/templates/roles.yaml

24 lines
522 B
YAML
Raw Permalink Normal View History

2024-07-13 20:21:59 +00:00
{{- if .Values.roles }}
{{- range $roles := .Values.roles }}
---
apiVersion: rbac.authorization.k8s.io/v1
kind: {{ $roles.kind }}
metadata:
name: {{ $roles.name }}
namespace: {{ $roles.namespace }}
labels:
{{- include "roles.labels" $ | nindent 4 }}
{{- with $roles.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with $roles.annotations}}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
rules:
{{- with $roles.rules }}
{{- toYaml . | nindent 2 }}
{{- end }}
{{- end }}
{{- end }}