mirror of
https://github.com/FlipsideCrypto/coredns-helm.git
synced 2026-02-06 10:56:50 +00:00
This is the common approach, stable doesnt make sense. Also since coredns is the only chart in this repo, link the README instead. Signed-off-by: Manuel Rüger <manuel@rueg.eu>
46 lines
1.0 KiB
YAML
46 lines
1.0 KiB
YAML
{{- if and .Values.deployment.enabled .Values.rbac.create }}
|
|
apiVersion: rbac.authorization.k8s.io/v1
|
|
kind: ClusterRole
|
|
metadata:
|
|
name: {{ template "coredns.fullname" . }}
|
|
labels:
|
|
app.kubernetes.io/managed-by: {{ .Release.Service | quote }}
|
|
app.kubernetes.io/instance: {{ .Release.Name | quote }}
|
|
helm.sh/chart: "{{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}"
|
|
{{- if .Values.isClusterService }}
|
|
k8s-app: {{ .Chart.Name | quote }}
|
|
kubernetes.io/cluster-service: "true"
|
|
kubernetes.io/name: "CoreDNS"
|
|
{{- end }}
|
|
app.kubernetes.io/name: {{ template "coredns.name" . }}
|
|
rules:
|
|
- apiGroups:
|
|
- ""
|
|
resources:
|
|
- endpoints
|
|
- services
|
|
- pods
|
|
- namespaces
|
|
verbs:
|
|
- list
|
|
- watch
|
|
- apiGroups:
|
|
- discovery.k8s.io
|
|
resources:
|
|
- endpointslices
|
|
verbs:
|
|
- list
|
|
- watch
|
|
{{- if .Values.rbac.pspEnable }}
|
|
- apiGroups:
|
|
- policy
|
|
- extensions
|
|
resources:
|
|
- podsecuritypolicies
|
|
verbs:
|
|
- use
|
|
resourceNames:
|
|
- {{ template "coredns.fullname" . }}
|
|
{{- end }}
|
|
{{- end }}
|