kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  name: custom-argocd-cluster-argocd-application-controller
rules:
  - verbs:
      - '*'
    apiGroups:
      - ''
    resources:
      - pods
      - services
      - services/finalizers
      - endpoints
      - events
      - configmaps
      - secrets
      - serviceaccounts
  - verbs:
      - '*'
    apiGroups:
      - 'triggers.tekton.dev'
    resources:
      - eventlisteners
      - triggerbindings
      - triggertemplates
  - verbs:
      - '*'
    apiGroups:
      - apps
    resources:
      - daemonsets
      - deployments
      - replicasets
      - statefulsets
  - verbs:
      - '*'
    apiGroups:
      - 'route.openshift.io'
    resources:
      - routes
  - verbs:
      - '*'
    apiGroups:
      - 'security.openshift.io'
    resources:
      - securitycontextconstraints
  - verbs:
      - '*'
    apiGroups:
      - 'operator.cert-manager.io'
    resources:
      - certmanagers
  - verbs:
      - '*'
    apiGroups:
      - 'cert-manager.io'
    resources:
      - clusterissuers
  - verbs:
      - '*'
    apiGroups:
      - 'bitnami.com'
    resources:
      - sealedsecretcontrollers
      - sealedsecrets
  - verbs:
      - '*'
    apiGroups:
      - 'integreatly.org'
    resources:
      - grafanas
      - grafanadatasources
      - grafanadashboards
  - verbs:
      - '*'
    apiGroups:
      - 'networking.k8s.io'
    resources:
      - networkpolicies
  - verbs:
      - '*'
    apiGroups:
      - 'integration.ibm.com'
    resources:
      - platformnavigators
  - verbs:
      - '*'
    apiGroups:
      - 'operators.coreos.com'
    resources:
      - subscriptions
  - verbs:
      - '*'
    apiGroups:
      - 'tekton.dev'
    resources:
      - pipelines
      - tasks
  - verbs:
      - '*'
    apiGroups:
      - 'maistra.io'
    resources:
      - servicemeshcontrolplanes
      - servicemeshmembers
      - servicemeshmemberrolls
  - verbs:
      - '*'
    apiGroups:
      - 'networking.istio.io'
    resources:
      - virtualservices
      - gateways
      - destinationrules
  - verbs:
      - create
      - list
    apiGroups:
      - ''
    resources:
      - events
  - verbs:
      - '*'
    apiGroups:
      - batch
    resources:
      - cronjobs
      - jobs
  - verbs:
      - '*'
    apiGroups:
      - argoproj.io
    resources:
      - applications
      - appprojects
  - verbs:
      - get
      - list
      - watch
    apiGroups:
      - '*'
    resources:
      - '*'
  - verbs:
      - get
      - list
    nonResourceURLs:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - operators.coreos.com
    resources:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - operator.openshift.io
    resources:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - user.openshift.io
    resources:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - config.openshift.io
    resources:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - console.openshift.io
    resources:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - ''
    resources:
      - namespaces
      - persistentvolumeclaims
      - persistentvolumes
      - configmaps
  - verbs:
      - '*'
    apiGroups:
      - rbac.authorization.k8s.io
    resources:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - storage.k8s.io
    resources:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - appconnect.ibm.com
    resources:
      - integrationservers
      - dashboards
      - configurations
  - verbs:
      - '*'
    apiGroups:
      - machineconfiguration.openshift.io
    resources:
      - machineconfigpools
      - containerruntimeconfigs
  - verbs:
      - '*'
    apiGroups:
      - tuned.openshift.io
    resources:
      - tuneds
  - verbs:
      - '*'
    apiGroups:
      - apiextensions.k8s.io
    resources:
      - customresourcedefinitions
  - verbs:
      - '*'
    apiGroups:
      - processmining.ibm.com
    resources:
      - processminings
  - verbs:
      - '*'
    apiGroups:
      - ocs.openshift.io
    resources:
      - storageclusters
  - verbs:
      - '*'
    apiGroups:
      - imageregistry.operator.openshift.io
    resources:
      - configs
  - verbs:
      - '*'
    apiGroups:
      - operator.ibm.com
    resources:
      - commonservices
  - verbs:
      - '*'
    apiGroups:
      - operator.ibm.com
    resources:
      - ibmlicensings
  - verbs:
      - '*'
    apiGroups:
      - mq.ibm.com
    resources:
      - queuemanagers
  - verbs:
      - '*'
    apiGroups:
      - icp4a.ibm.com
    resources:
      - icp4aclusters
  - apiGroups:              # API Connect
      - apiconnect.ibm.com  # API Connect specific API groups
      - management.apiconnect.ibm.com
      - portal.apiconnect.ibm.com
      - gateway.apiconnect.ibm.com
      - analytics.apiconnect.ibm.com
      - datapower.ibm.com   # DataPower specific API groups
    resources:
      - '*'
    verbs:
      - '*'
  - apiGroups:              # API Connect Multicloud use case
      - certmanager.k8s.io
      - apps.openshift.io
      - build.openshift.io
      - image.openshift.io
      - cert-manager.io
    resources:
      - 'certificates'
      - 'issuers'
      - 'deploymentconfigs'
      - 'imagestreams'
      - 'buildconfigs'
    verbs:
      - '*'
  - verbs:
      - '*'
    apiGroups:
      - operator.ibm.com
    resources:
      - operandrequests
  - verbs:
      - '*'
    apiGroups:
      - cpd.ibm.com
    resources:
      - ibmcpds
  - verbs:
      - '*'
    apiGroups:
      - ocp.spp.ibm.com
    resources:
      - ibmspps
  - verbs:
      - '*'
    apiGroups:
      - konveyor.openshift.io
    resources:
      - veleros
  - verbs:
      - '*'
    apiGroups:
      - autoscaling
    resources:
      - horizontalpodautoscalers
  - verbs:
      - '*'
    apiGroups:
      - kafka.strimzi.io
    resources:
      - kafkas
      - kafkausers
  - verbs:
      - '*'
    apiGroups:
      - isc.ibm.com
    resources:
      - cp4sthreatmanagements
  - verbs:
      - '*'
    apiGroups:
      - ws.cpd.ibm.com
    resources:
      - ws
