---
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  name: cluster-image-registry-operator
rules:
- apiGroups:
  - imageregistry.operator.openshift.io
  resources:
  - "configs"
  - "configs/status"
  - "imagepruners"
  - "imagepruners/status"
  verbs:
  - "*"
- apiGroups:
  - config.openshift.io
  resources:
  - "clusteroperators"
  - "images"
  - "images/status"
  verbs:
  - "*"
- apiGroups:
  - config.openshift.io
  resources:
  - infrastructures
  verbs:
  - get
  - list
  - watch
- apiGroups:
  - ""
  resources:
  - configmaps
  - endpoints
  - events
  - namespaces
  - persistentvolumeclaims
  - pods
  - secrets
  - services
  verbs:
  - "*"
- apiGroups:
  - batch
  resources:
  - cronjobs
  - jobs
  verbs:
  - "*"
- apiGroups:
  - apps
  resources:
  - daemonsets
  - deploymentconfigs
  - deployments
  - replicasets
  - statefulsets
  verbs:
  - "*"
- apiGroups:
  - apps.openshift.io
  resources:
  - deploymentconfigs
  verbs:
  - "*"
- apiGroups:
  - ""
  resources:
  - serviceaccounts
  verbs:
  - "*"
- apiGroups:
  - rbac.authorization.k8s.io
  resources:
  - clusterroles
  - clusterrolebindings
  verbs:
  - "*"
- apiGroups:
  - ""
  resources:
  - limitranges
  - resourcequotas
  verbs:
  - list
- apiGroups:
  - image.openshift.io
  resources:
  - "*"
  verbs:
  - "*"
- apiGroups:
  - route.openshift.io
  resources:
  - routes
  - routes/custom-host
  verbs:
  - "*"
- apiGroups:
  - config.openshift.io
  resources:
  - clusteroperators
  - clusteroperators/status
  verbs:
  - create
  - get
  - update
- apiGroups:
  - config.openshift.io
  resources:
  - proxies
  verbs:
  - list
  - get
  - watch
---
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  name: default-account-cluster-image-registry-operator
subjects:
- kind: ServiceAccount
  name: cluster-image-registry-operator
  namespace: openshift-image-registry
roleRef:
  kind: ClusterRole
  name: cluster-image-registry-operator
  apiGroup: rbac.authorization.k8s.io
