Service Account, Role, Cluster Role

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/5bc428be-eef0-41ee-94b6-02d5e322688c/_2021-07-20__9.42.51.png

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/241f4138-0614-4eff-914a-c70a9a9b51a0/_2021-07-20__9.44.17.png

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/906996d9-09f1-462e-9b1c-7ee852870441/_2021-07-20__9.44.43.png

apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
	namespace: default
	name: service-reader
rules:
- apiGroups: [""]
	resources: ["services"]
	verbs: ["get", "list"]
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
	namespace: default
	name: service-reader-rolebinding
subjects:
- kind: ServiceAccount
	name: testAccount
	namespace: default
roleRef:
	kind: Role
	name: service-reader
	apiGroup: rbac.authorization.k8s.io

User, Group