# helm_charts_cluster_role_binding.yaml
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
  name: {{ .Values.logdna.name }}
  labels:
    app.kubernetes.io/name: {{ template "logdna.name" . }}
    app.kubernetes.io/managed-by: {{ .Release.Service }}
    app.kubernetes.io/instance: {{ .Release.Name }}
    app.kubernetes.io/version: {{ .Chart.AppVersion }}
    helm.sh/chart: {{ template "logdna.chart" . }}
roleRef:
  apiGroup: rbac.authorization.k8s.io
  kind: ClusterRole
  name: {{ .Values.logdna.name }}
subjects:
  - kind: ServiceAccount
    name: {{ template "logdna.serviceAccountName" . }}
    namespace: {{ .Release.Namespace }}