- clusteradmin create clusterset
server-foundation-clusterset
oc apply -f managedclusterset.yaml
-
clusteradmin grant permission to server-foundation team 2.1 clusteradmin grant
self-provisioner
permission toserver-foundation-team-admin
2.2 clusteradmin grant
clusterset admin
permission toserver-foundation-team-admin
2.3 clusteradmin grant
clusterset view
permission toserver-foundation-team-view
oc adm policy add-cluster-role-to-user open-cluster-management:clusterset-admin:server-foundation-clusterset le jian
oc adm policy add-cluster-role-to-user open-cluster-management:clusterset-view:server-foundation-clusterset dangpeng
oc adm policy add-cluster-role-to-group self-provisioner le jian
- As team-admin le create a project
managedcluster1
oc new-project managedcluster1 --as le
- As team-admin, Le creates a managedcluster managedcluster1 with clusterset label
oc apply -f managedcluster1.yaml
- As another team-admin, jian can edit managedcluster1.
oc get managedclusters
oc label managedcluster managedcluster1 testlabel=test
- as team-user, dangpeng cann view managedcluster1
oc get managedclusters
oc label managedcluster managedcluster1 testlabel=test1 --as jian