×

模拟允许您以其他用户身份创建项目。

API 模拟

您可以将对 OpenShift Container Platform API 的请求配置为模拟它来自其他用户。更多信息,请参阅 Kubernetes 文档中的用户模拟

创建项目时模拟用户

创建项目请求时,您可以模拟不同的用户。因为system:authenticated:oauth是唯一可以创建项目请求的引导组,所以您必须模拟该组。

步骤
  • 以其他用户身份创建项目请求

    $ oc new-project <project> --as=<user> \
        --as-group=system:authenticated --as-group=system:authenticated:oauth