---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  name: ako-operator-manager-role
rules:
- apiGroups: [""]
  resources: ["configmaps", "configmaps/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
- apiGroups: [""]
  resources: ["serviceaccounts", "serviceaccounts/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
- apiGroups: ["ako.vmware.com"]
  resources: ["akoconfigs", "akoconfigs/status", "akoconfigs/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
- apiGroups: ["apps"]
  resources: ["statefulsets", "statefulsets/status", "statefulsets/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
- apiGroups: ["policy"]
  resources: ["podsecuritypolicies", "podsecuritypolicies/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
- apiGroups: ["rbac.authorization.k8s.io"]
  resources: ["clusterrolebindings", "clusterroles", "clusterrolebindings/finalizers", "clusterroles/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
- apiGroups: ["extensions", "networking.k8s.io"]
  resources: ["ingresses", "ingresses/status"]
  verbs: ["create", "delete", "get", "watch", "list", "patch", "update"]
- apiGroups: [""]
  resources: ["services", "services/status"]
  verbs: ["create", "get", "watch", "list", "patch", "update"]
- apiGroups: [""]
  resources: ["events"]
  verbs: ["create", "patch", "update"]
- apiGroups: ["crd.projectcalico.org"]
  resources: ["blockaffinities", "blockaffinities/status"]
  verbs: ["get", "watch", "list"]
- apiGroups: ["network.openshift.io"]
  resources: ["hostsubnets"]
  verbs: ["create", "delete", "get", "watch", "list", "patch", "update"]
- apiGroups: ["route.openshift.io"]
  resources: ["routes", "routes/status"]
  verbs: ["create", "delete", "get", "watch", "list", "patch", "update"]
- apiGroups: ["ako.vmware.com"]
  resources: ["hostrules", "hostrules/status", "hostrules/finalizers", "httprules", "httprules/status", "httprules/finalizers", "aviinfrasettings", "aviinfrasettings/status", "aviinfrasettings/finalizers"]
  verbs: ["create", "delete", "get", "watch", "list", "patch", "update"]
- apiGroups: ["apiextensions.k8s.io"]
  resources: ["customresourcedefinitions", "customresourcedefinitions/status", "customresourcedefinitions/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
- apiGroups: ["networking.x-k8s.io"]
  resources: ["gateways", "gateways/status", "gatewayclasses", "gateways/finalizers", "gatewayclasses/status", "gatewayclasses/finalizers"]
  verbs: ["create", "delete", "get", "watch", "list", "patch", "update"]
- apiGroups: [""]
  resources: ["*"]
  verbs: ['get', 'watch', 'list']
- apiGroups: ["networking.k8s.io"]
  resources: ["ingressclasses", "ingressclasses/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
- apiGroups: [""]
  resources: ["secrets", "secrets/status", "secrets/finalizers"]
  verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
