You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

55 lines
1.3 KiB

  1. ---
  2. kind: ServiceAccount
  3. apiVersion: v1
  4. metadata:
  5. name: vsphere-csi-node
  6. namespace: "{{ vsphere_csi_namespace }}"
  7. ---
  8. kind: ClusterRole
  9. apiVersion: rbac.authorization.k8s.io/v1
  10. metadata:
  11. name: vsphere-csi-node-cluster-role
  12. rules:
  13. - apiGroups: ["cns.vmware.com"]
  14. resources: ["csinodetopologies"]
  15. verbs: ["create", "watch", "get", "patch" ]
  16. - apiGroups: [""]
  17. resources: ["nodes"]
  18. verbs: ["get"]
  19. ---
  20. kind: ClusterRoleBinding
  21. apiVersion: rbac.authorization.k8s.io/v1
  22. metadata:
  23. name: vsphere-csi-node-cluster-role-binding
  24. subjects:
  25. - kind: ServiceAccount
  26. name: vsphere-csi-node
  27. namespace: "{{ vsphere_csi_namespace }}"
  28. roleRef:
  29. kind: ClusterRole
  30. name: vsphere-csi-node-cluster-role
  31. apiGroup: rbac.authorization.k8s.io
  32. ---
  33. kind: Role
  34. apiVersion: rbac.authorization.k8s.io/v1
  35. metadata:
  36. name: vsphere-csi-node-role
  37. namespace: "{{ vsphere_csi_namespace }}"
  38. rules:
  39. - apiGroups: [""]
  40. resources: ["configmaps"]
  41. verbs: ["get", "list", "watch"]
  42. ---
  43. kind: RoleBinding
  44. apiVersion: rbac.authorization.k8s.io/v1
  45. metadata:
  46. name: vsphere-csi-node-binding
  47. namespace: "{{ vsphere_csi_namespace }}"
  48. subjects:
  49. - kind: ServiceAccount
  50. name: vsphere-csi-node
  51. namespace: "{{ vsphere_csi_namespace }}"
  52. roleRef:
  53. kind: Role
  54. name: vsphere-csi-node-role
  55. apiGroup: rbac.authorization.k8s.io