有没有办法在openshift中列出默认组中的用户?

有没有办法在openshift中列出默认组中的用户?,openshift,usergroups,Openshift,Usergroups,我想在openshift中列出默认组中的用户,例如system:authenticated、system:authenticated:oauth、system:unauthenticated 我得到 查找默认组和角色,但无法列出这些组中的用户。所以我想知道有没有办法在openshift集群中列出 “oc get group”不会列出默认组和用户。您可以按如下方式验证当前角色绑定。 有关更多详细信息,请参阅 $ oc describe clusterrolebinding.rbac 它显示了与特

我想在openshift中列出默认组中的用户,例如system:authenticated、system:authenticated:oauth、system:unauthenticated

我得到 查找默认组和角色,但无法列出这些组中的用户。所以我想知道有没有办法在openshift集群中列出


“oc get group”
不会列出默认组和用户。

您可以按如下方式验证当前角色绑定。 有关更多详细信息,请参阅

$ oc describe clusterrolebinding.rbac
它显示了与特定组和用户的角色绑定。 例如,
basic用户
可以
system:authenticated

Name:       basic-users
Labels:     <none>
Annotations:    rbac.authorization.kubernetes.io/autoupdate=true
Role:
  Kind: ClusterRole
  Name: basic-user
Subjects:
  Kind  Name            Namespace
  ----  ----            ---------
  Group system:authenticated

谢谢你的回答。但具体来说,我正在寻找一种从默认组(系统:authenticated)中列出用户列表的方法。像这样#oc get groups NAME USERS west john,BETTYUN幸运的是,没有一种使用cli列出它的方法。但您可以从这里验证完整列表:@Deain我试图从clusterrolebinding中列出特定用户的角色和权限。但它是空的。所以我的假设是,它们可能是默认组的一部分,比如system:authenticated、system:authenticated:oauth和system:unauthenticated。所以我想检查他们属于哪一组。那么,有没有其他方法可以找到特定用户的角色和权限???下面是我用来获取角色“oc descripe clusterrolebinding | grep-B2$username | awk{'print$1$2'}| grep Role | sed's/Role://g'@sandhya您无法使用CLI验证
系统:
的成员<代码>默认组意味着隐式应用所有用户。例如,
system:authenticated
适用于所有经过身份验证的用户,
system:unauthenticated
适用于所有未经身份验证的用户。
Name:       admin
Labels:     <none>
Annotations:    <none>
Role:
  Kind: ClusterRole
  Name: admin
Subjects:
  Kind  Name    Namespace
  ----  ----    ---------
  User  joe