apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
  name: watson-assistant-operator-role
  labels:
    operator: watson-assistant-operator
rules:
  - apiGroups:
      - ""
      - batch
    resources:
      - pods
      - pods/status
      - services
      - services/finalizers
      - endpoints
      - persistentvolumeclaims
      - events
      - configmaps
      - secrets
      - jobs
      - cronjobs
      - serviceaccounts
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
      - deletecollection
  - apiGroups:
      - networking.k8s.io
    resources:
      - networkpolicies
    verbs:
      - create
      - delete
      - deletecollection
      - get
      - list
      - patch
      - update
      - watch
  - apiGroups:
      - rbac.authorization.k8s.io
    resources:
      - rolebindings
      - roles
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
      - deletecollection
  - apiGroups:
      - apps
    resources:
      - deployments
      - replicasets
      - statefulsets
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
      - deletecollection
  - apiGroups:
      - monitoring.coreos.com
    resources:
      - servicemonitors
    verbs:
      - get
      - create
  - apiGroups:
      - apps
    resources:
      - deployments/finalizers
    verbs:
      - update
  - apiGroups:
      - ""
    resources:
      - pods/log
    verbs:
      - create
      - delete
      - get
      - list
      - patch
      - update
      - watch
  - apiGroups:
      - ""
    resources:
      - resourcequotas
      - resourcequotas/status
    verbs:
      - get
      - list
      - watch
  - apiGroups:
      - com.ibm.watson.watson-assistant
    resources:
      - '*'
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
      - deletecollection
  - apiGroups:
      - policy
    resources:
      - poddisruptionbudgets
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
      - deletecollection
  - apiGroups:
      - autoscaling
    resources:
      - horizontalpodautoscalers
    verbs:
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
      - deletecollection
  - apiGroups:
      - redis.databases.cloud.ibm.com
    resources:
      - redissentinels
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
  - apiGroups:
      - etcd.database.coreos.com
    resources:
      - etcdclusters
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
  - apiGroups:
      - ibmevents.ibm.com
    resources:
      - kafkas
      - kafkausers
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
  - apiGroups:
      - elasticsearch.k8s.elastic.co
    resources:
      - elasticsearches
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
  - apiGroups:
      - elasticsearch.cloudpackopen.ibm.com
    resources:
      - elasticsearches
      - elasticsearchdetails
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
  - apiGroups:
      - helm.operator-sdk
    resources:
      - ibmminios
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
  - apiGroups:
      - edbpostgres.com
    resources:
      - edbpostgres
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
  - apiGroups:
      - com.ibm.watson.watson-gateway
    resources:
      - watsongateways
    verbs:
      - apply
      - create
      - get
      - delete
      - watch
      - update
      - edit
      - list
      - patch
  - apiGroups:
      - com.ibm.oppy
    resources:
      - temporarypatches
      - temporarypatches/status
    verbs:
      - get
      - watch
      - list
      - update
      - patch
