apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  name: external-secrets-cert-controller
  labels:
    helm.sh/chart: external-secrets-2.0.0
    app.kubernetes.io/name: external-secrets-cert-controller
    app.kubernetes.io/instance: external-secrets
    app.kubernetes.io/version: "v2.0.0"
    app.kubernetes.io/managed-by: Helm
rules:
  - apiGroups:
      - "apiextensions.k8s.io"
    resources:
      - "customresourcedefinitions"
    verbs:
      - "get"
      - "list"
      - "watch"
      - "update"
      - "patch"
  - apiGroups:
      - "admissionregistration.k8s.io"
    resources:
      - "validatingwebhookconfigurations"
    verbs:
      - "list"
      - "watch"
      - "get"
  - apiGroups:
      - "admissionregistration.k8s.io"
    resources:
      - "validatingwebhookconfigurations"
    resourceNames:
      - "secretstore-validate"
      - "externalsecret-validate"
    verbs:
      - "update"
      - "patch"
  - apiGroups:
      - ""
    resources:
      - "endpoints"
    verbs:
      - "list"
      - "get"
      - "watch"
  - apiGroups:
      - "discovery.k8s.io"
    resources:
      - "endpointslices"
    verbs:
      - "list"
      - "get"
      - "watch"
  - apiGroups:
      - ""
    resources:
      - "events"
    verbs:
      - "create"
      - "patch"
  - apiGroups:
      - ""
    resources:
      - "secrets"
    verbs:
      - "get"
      - "list"
      - "watch"
      - "update"
      - "patch"
  - apiGroups:
      - "coordination.k8s.io"
    resources:
      - "leases"
    verbs:
      - "get"
      - "create"
      - "update"
      - "patch"
