[create a Namespace]
$ kubectl create namespace developers

[create the Role]
$ kubectl create role dev-role --verb=get,list,create --resource=deployments,pods -n developers

[create the RoleBinding]
$ kubectl create rolebinding dev-rb --role=developers --user=ege -n developers

[create a ServiceAccount]
$ kubectl create serviceaccount dev-sa -n developers

[create the RoleBinding]
$ kubectl create rolebinding dev-sa-rb --role=dev-role --serviceaccount=developers:dev-sa

[create a Namespace]
$ kubectl create namespace testers

[create the Role]
$ kubectl create role tester-role --verb=list --resource=pods -n testers

[create a ServiceAccount]
$ kubectl create serviceaccount tester-sa -n testers

[create the RoleBinding]
$ kubectl create rolebinding tester-rb --role=tester-role --serviceaccount=testers:tester-sa -n testers

[create the ClusterRole]
$ kubectl create clusterrole devops-role --verb=list --resource=pods

[create a ServiceAccount]
$ kubectl create serviceaccount devops-sa

[create the ClusterRoleBinding]
$ kubectl create clusterrolebinding devops-rb --clusterrole=devops-role --serviceaccount=default:devops-sa

[check the status by using an get]
$ kubectl get roles
$ kubectl get roles -n developers
$ kubectl get roles -n testers

[check the status by using an describe]
$ kubectl describe role dev-role -n developers

[Authorization]
$ kubectl auth can-i create deployments
yes
$ kubectl auth can-i list pods --as dev-sa
no
$ kubectl auth can-i delete deployments --as tester-sa
no
