apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  labels:
    app.kubernetes.io/component: webhook
    app.kubernetes.io/instance: default
    app.kubernetes.io/part-of: tekton-pipelines
  name: tekton-pipelines-webhook-cluster-access
rules:
- apiGroups:
  - apiextensions.k8s.io
  resourceNames:
  - pipelines.tekton.dev
  - pipelineruns.tekton.dev
  - runs.tekton.dev
  - tasks.tekton.dev
  - clustertasks.tekton.dev
  - taskruns.tekton.dev
  - pipelineresources.tekton.dev
  - conditions.tekton.dev
  resources:
  - customresourcedefinitions
  - customresourcedefinitions/status
  verbs:
  - get
  - update
  - patch
- apiGroups:
  - apiextensions.k8s.io
  resources:
  - customresourcedefinitions
  verbs:
  - list
  - watch
- apiGroups:
  - admissionregistration.k8s.io
  resources:
  - mutatingwebhookconfigurations
  - validatingwebhookconfigurations
  verbs:
  - list
  - watch
- apiGroups:
  - admissionregistration.k8s.io
  resourceNames:
  - webhook.pipeline.tekton.dev
  resources:
  - mutatingwebhookconfigurations
  verbs:
  - get
  - update
  - delete
- apiGroups:
  - admissionregistration.k8s.io
  resourceNames:
  - validation.webhook.pipeline.tekton.dev
  - config.webhook.pipeline.tekton.dev
  resources:
  - validatingwebhookconfigurations
  verbs:
  - get
  - update
  - delete
- apiGroups:
  - policy
  resourceNames:
  - tekton-pipelines
  resources:
  - podsecuritypolicies
  verbs:
  - use
- apiGroups:
  - ""
  resourceNames:
  - tekton-pipelines
  resources:
  - namespaces
  verbs:
  - get
- apiGroups:
  - ""
  resourceNames:
  - tekton-pipelines
  resources:
  - namespaces/finalizers
  verbs:
  - update
