apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRole
metadata:
  name: aws-operator
  namespace: giantswarm
rules:
  - apiGroups:
      - "core.giantswarm.io"
    resources:
      - storageconfigs
    verbs:
      - get
      - list
      - watch
      - create
      - update
      - patch
      - delete
  - apiGroups:
      - "provider.giantswarm.io"
    resources:
      - awsconfigs
    verbs:
      - get
      - list
      - watch
      - create
      - update
      - patch
      - delete
  - apiGroups:
      - ""
    resources:
      - namespaces
    verbs:
      - get
      - list
      - watch
      - create
      - update
      - patch
      - delete
  - apiGroups:
      - ""
    resources:
      - pods
      - configmaps
      - secrets
      - resourcequotas
      - limitranges
      - nodes
      - persistenvolumes
      - persistenvolumeclaims
      - podtemplates
      - replicationcontroller
      - serviceaccounts
    verbs:
      - list
      - watch
  - apiGroups:
      - ""
    resources:
      - endpoints
      - services
    verbs:
      - create
      - list
      - watch
---
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
  name: userd
subjects:
  - kind: ServiceAccount
    name: aws-operator
roleRef:
  kind: ClusterRole
  name: aws-operator
  apiGroup: rbac.authorization.k8s.io

apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRole
metadata:
  name: aws-operator
  namespace: giantswarm
rules:
  - apiGroups:
      - "core.giantswarm.io"
    resources:
      - storageconfigs
    verbs:
      - get
      - list
      - watch
      - create
      - update
      - patch
      - delete
  - apiGroups:
      - "provider.giantswarm.io"
    resources:
      - awsconfigs
    verbs:
      - get
      - list
      - watch
      - create
      - update
      - patch
      - delete
  - apiGroups:
      - ""
    resources:
      - namespaces
    verbs:
      - get
      - list
      - watch
      - create
      - update
      - patch
      - delete
  - apiGroups:
      - ""
    resources:
      - pods
      - configmaps
      - secrets
      - resourcequotas
      - limitranges
      - nodes
      - persistenvolumes
      - persistenvolumeclaims
      - podtemplates
      - replicationcontroller
      - serviceaccounts
    verbs:
      - list
      - watch
  - apiGroups:
      - ""
    resources:
      - endpoints
      - services
    verbs:
      - create
      - list
      - watch
---
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
  name: aws-operator
subjects:
  - kind: ServiceAccount
    name: aws-operator
roleRef:
  kind: ClusterRole
  name: aws-operator
  apiGroup: rbac.authorization.k8s.io

Correct name for the cluster role binding
Correct name for the cluster role binding
