# borrowed from https://cloud.weave.works/k8s/scope.yaml?k8s-version=1.9.3
# with little modificatios to reduce permissions
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  labels:
    name: weave-scope
  name: weave-scope
  namespace: weave
rules:
- apiGroups:
  - ""
  resources:
  - pods
  - replicationcontrollers
  - services
  - nodes
  verbs:
  - list
  - watch
- apiGroups:
  - apps
  resources:
  - statefulsets
  verbs:
  - list
  - watch
- apiGroups:
  - batch
  resources:
  - cronjobs
  - jobs
  verbs:
  - list
  - watch
- apiGroups:
  - extensions
  resources:
  - daemonsets
  - deployments
  - replicasets
  verbs:
  - list
  - watch

# borrowed from https://cloud.weave.works/k8s/scope.yaml?k8s-version=1.9.3
# with little modificatios to reduce permissions
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  labels:
    name: weave-scope
  name: weave-scope
  namespace: weave
rules:
- apiGroups:
  - ""
  resources:
  - pods
  - replicationcontrollers
  - services
  - nodes
  - persistentvolumes
  - persistentvolumeclaims
  verbs:
  - list
  - watch
- apiGroups:
  - apps
  resources:
  - statefulsets
  verbs:
  - list
  - watch
- apiGroups:
  - batch
  resources:
  - cronjobs
  - jobs
  verbs:
  - list
  - watch
- apiGroups:
  - extensions
  resources:
  - daemonsets
  - deployments
  - replicasets
  verbs:
  - list
  - watch
- apiGroups:
  - storage.k8s.io
  resources:
  - storageclasses
  verbs:
  - list
  - watch

Add rules in cluster role for k8s storage components
Add rules in cluster role for k8s storage components

This will add rules to cluster role for k8s storage components.
These RBAC permissions are required for scope to fetch details about PV, PVC, SC
resources.

Signed-off-by: Satyam Zode <1b501fb713b97270deb59324557facac5b2a4e46@gmail.com>
