apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  labels:
    app.kubernetes.io/component: kubevirt
    app.kubernetes.io/managed-by: virt-operator
    kubevirt.io: ""
  name: kubevirt-handler
rules:
  - apiGroups:
      - kubevirt.io
    resources:
      - virtualmachineinstances
    verbs:
      - update
      - list
      - watch
  - apiGroups:
      - ""
    resources:
      - nodes
    verbs:
      - patch
      - list
      - watch
      - get
  - apiGroups:
      - ""
    resources:
      - configmaps
    verbs:
      - get
      - list
      - watch
  - apiGroups:
      - ""
    resources:
      - events
    verbs:
      - create
      - patch
  - apiGroups:
      - apiextensions.k8s.io
    resources:
      - customresourcedefinitions
    verbs:
      - get
      - list
      - watch
  - apiGroups:
      - kubevirt.io
    resources:
      - kubevirts
    verbs:
      - get
      - list
      - watch
  - apiGroups:
      - migrations.kubevirt.io
    resources:
      - migrationpolicies
    verbs:
      - get
      - list
      - watch