Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ kubectl auth can-i list deployments.apps
# 检查命名空间 "dev" 的服务帐户 "foo" 是否可以列出命名空间 "prod" 下的 Pod。
# 你必须有权限使用全局选项 "--as" 所涉及的身份伪装功能。
kubectl auth can-i list pods --as=system:serviceaccount:dev:foo -n prod

# 检查我是否可以在当前命名空间中执行所有操作("*" 表示全部)
kubectl auth can-i '*' '*'

Expand Down Expand Up @@ -109,7 +109,8 @@ kubectl auth can-i --list --namespace=foo
If true, check the specified action in all namespaces.
-->
如果为 true,则在所有命名空间中执行指定的操作。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -122,7 +123,8 @@ If true, check the specified action in all namespaces.
help for can-i
-->
关于 can-i 的帮助信息。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -135,7 +137,8 @@ help for can-i
If true, prints all allowed actions.
-->
如果为真,则打印所有允许的操作。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -148,7 +151,8 @@ If true, prints all allowed actions.
If true, prints allowed actions without headers
-->
如果为真,则打印允许的操作而不打印标题。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -161,7 +165,8 @@ If true, prints allowed actions without headers
If true, suppress output and just return the exit code.
-->
如果为真,则抑制输出并仅返回退出代码。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -174,7 +179,8 @@ If true, suppress output and just return the exit code.
SubResource such as pod/log or deployment/scale
-->
子资源(例如 pod/log 或 deploy/scale)。
</p></td>
</p>
</td>
</tr>

</tbody>
Expand All @@ -199,7 +205,8 @@ SubResource such as pod/log or deployment/scale
Username to impersonate for the operation. User could be a regular user or a service account in a namespace.
-->
操作所用的伪装用户名。用户可以是常规用户或命名空间中的服务账号。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -212,7 +219,8 @@ Username to impersonate for the operation. User could be a regular user or a ser
Group to impersonate for the operation, this flag can be repeated to specify multiple groups.
-->
操作所用的伪装用户组,此标志可以被重复设置以指定多个组。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -225,7 +233,22 @@ Group to impersonate for the operation, this flag can be repeated to specify mul
UID to impersonate for the operation.
-->
操作所用的伪装 UID。
</p></td>
</p>
</td>
</tr>

<tr>
<td colspan="2">--as-user-extra strings</td>
</tr>
<tr>
<td></td><td style="line-height: 130%; word-wrap: break-word;">
<p>
<!--
User extras to impersonate for the operation, this flag can be repeated to specify multiple values for the same key.
-->
用户额外信息,用于伪装操作,此标志可以重复使用,为同一个键指定多个值。
</p>
</td>
</tr>

<tr>
Expand All @@ -238,7 +261,8 @@ UID to impersonate for the operation.
Default cache directory
-->
默认缓存目录。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -251,7 +275,8 @@ Default cache directory
Path to a cert file for the certificate authority
-->
证书机构的证书文件的路径。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -264,7 +289,8 @@ Path to a cert file for the certificate authority
Path to a client certificate file for TLS
-->
TLS 客户端证书文件的路径。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -277,7 +303,8 @@ TLS 客户端证书文件的路径。
Path to a client key file for TLS
-->
TLS 客户端密钥文件的路径。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -290,7 +317,8 @@ TLS 客户端密钥文件的路径。
The name of the kubeconfig cluster to use
-->
要使用的 kubeconfig 中集群的名称。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -303,7 +331,8 @@ The name of the kubeconfig cluster to use
The name of the kubeconfig context to use
-->
要使用的 kubeconfig 上下文的名称。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -316,7 +345,8 @@ The name of the kubeconfig context to use
If true, opt-out of response compression for all requests to the server
-->
如果为 true,则对服务器所有请求的响应不再压缩。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -329,7 +359,8 @@ If true, opt-out of response compression for all requests to the server
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure
-->
如果为 true,则不检查服务器证书的有效性。这将使你的 HTTPS 连接不安全。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -342,7 +373,8 @@ If true, the server's certificate will not be checked for validity. This will ma
Path to the kubeconfig file to use for CLI requests.
-->
CLI 请求要使用的 kubeconfig 文件的路径。
</p></td>
</p>
</td>
</tr>

<tr>
Expand Down Expand Up @@ -370,7 +402,8 @@ Path to the kuberc file to use for preferences. This can be disabled by exportin
Require server version to match client version
-->
要求服务器版本与客户端版本匹配。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -383,7 +416,8 @@ Require server version to match client version
If present, the namespace scope for this CLI request
-->
如果存在,则是此 CLI 请求的命名空间范围。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -396,7 +430,8 @@ If present, the namespace scope for this CLI request
Password for basic authentication to the API server
-->
对 API 服务器进行基本身份验证所用的密码。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -406,10 +441,11 @@ Password for basic authentication to the API server
<td></td><td style="line-height: 130%; word-wrap: break-word;">
<p>
<!--
Name of profile to capture. One of (none|cpu|heap|goroutine|threadcreate|block|mutex)
Name of profile to capture. One of (none|cpu|heap|goroutine|threadcreate|block|mutex|trace)
-->
要记录的性能分析信息。可选值为(none|cpu|heap|goroutine|threadcreate|block|mutex)。
</p></td>
要记录的性能分析信息。可选值为(none|cpu|heap|goroutine|threadcreate|block|mutex|trace)。
</p>
</td>
</tr>

<tr>
Expand All @@ -422,7 +458,8 @@ Name of profile to capture. One of (none|cpu|heap|goroutine|threadcreate|block|m
Name of the file to write the profile to
-->
性能分析信息要写入的目标文件的名称。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -436,7 +473,8 @@ The length of time to wait before giving up on a single server request. Non-zero
-->
在放弃某个服务器请求之前等待的时长。非零值应包含相应的时间单位(例如 1s、2m、3h)。
值为零表示请求不会超时。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -449,7 +487,8 @@ The length of time to wait before giving up on a single server request. Non-zero
The address and port of the Kubernetes API server
-->
Kubernetes API 服务器的地址和端口。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -462,7 +501,8 @@ Kubernetes API 服务器的地址和端口。
Writes in the storage driver will be buffered for this duration, and committed to the non memory backends as a single transaction
-->
对存储驱动的写入操作将被缓存的时长;缓存的操作会作为一个事务提交给非内存后端。
</p></td>
</p>
</td>
</tr>

<tr>
Expand All @@ -475,7 +515,8 @@ Writes in the storage driver will be buffered for this duration, and committed t
database name
-->
数据库名称。
</p></td>
</p>
</td>
</tr>

<tr>
Expand Down