# Role for the operator itself.
kind: Role
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  name: ingress-operator
  namespace: openshift-ingress-operator
  annotations:
    include.release.openshift.io/ibm-cloud-managed: "true"
    include.release.openshift.io/self-managed-high-availability: "true"
    include.release.openshift.io/single-node-developer: "true"
rules:
- apiGroups:
  - operator.openshift.io
  resources:
  - "*"
  verbs:
  - "*"

- apiGroups:
  - ""
  resources:
  - pods
  - services
  - endpoints
  - persistentvolumeclaims
  - events
  - configmaps
  - secrets
  verbs:
  - "*"

- apiGroups:
  - apps
  resources:
  - deployments
  - services
  verbs:
  - "*"
---
# Role for the operator to delete Role and RoleBindings
# in the openshift-config namespace.
kind: Role
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  name: ingress-operator
  namespace: openshift-config
  annotations:
    include.release.openshift.io/ibm-cloud-managed: "true"
    include.release.openshift.io/self-managed-high-availability: "true"
    include.release.openshift.io/single-node-developer: "true"
rules:
- apiGroups:
  - rbac.authorization.k8s.io
  resources:
  - roles
  - rolebindings
  verbs:
  - delete
