RBAC

How do we create a role?

The next step is to link the user to that role : RoleBinding

apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
	name: developer
rules:
- apiGroups: [""]
	resource: ["pods"]
	verbs: ["get", "list", "update", "delete", "create"]
- apiGroups: [""]
	resources: ["ConfigMap"]
	verbs: ["create]
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
	name: devuser-developer-binding
subjects:
- kind: User
	name: dev-user # "name" is case sensitive
  apiGroup: rbac.authorization.k8s.io
roleRef:
	kind: Role
	name: developer
	apiGroup: rbac.authorization.k8s.io

Untitled

RBAC 보기