Skip to content

Commit dcb347f

Browse files
authored
Merge pull request #37199 from windsonsea/labann
[zh] Sync /labels-annotations-taints/_index.md
2 parents ccb6a36 + 5f55f30 commit dcb347f

File tree

1 file changed

+67
-16
lines changed
  • content/zh-cn/docs/reference/labels-annotations-taints

1 file changed

+67
-16
lines changed

content/zh-cn/docs/reference/labels-annotations-taints/_index.md

Lines changed: 67 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1068,6 +1068,25 @@ You should **not** manually add or remove this annotation.
10681068
Job 上存在此注解表明控制平面正在[使用 Finalizer 追踪 Job](/zh-cn/docs/concepts/workloads/controllers/job/#job-tracking-with-finalizers)
10691069
**** 可以手动添加或删除此注解。
10701070

1071+
<!--
1072+
### scheduler.alpha.kubernetes.io/defaultTolerations {#scheduleralphakubernetesio-defaulttolerations}
1073+
1074+
Example: `scheduler.alpha.kubernetes.io/defaultTolerations: '[{"operator": "Equal", "value": "value1", "effect": "NoSchedule", "key": "dedicated-node"}]'`
1075+
1076+
Used on: Namespace
1077+
1078+
This annotation requires the [PodTolerationRestriction](/docs/reference/access-authn-authz/admission-controllers/#podtolerationrestriction) admission controller to be enabled. This annotation key allows assigning tolerations to a namespace and any new pods created in this namespace would get these tolerations added.
1079+
-->
1080+
### scheduler.alpha.kubernetes.io/defaultTolerations {#scheduleralphakubernetesio-defaulttolerations}
1081+
1082+
例子:`scheduler.alpha.kubernetes.io/defaultTolerations: '[{"operator": "Equal", "value": "value1", "effect": "NoSchedule", "key": "dedicated-node"}]'`
1083+
1084+
用于:Namespace
1085+
1086+
此注解需要启用
1087+
[PodTolerationRestriction](/zh-cn/docs/reference/access-authn-authz/admission-controllers/#podtolerationrestriction)
1088+
准入控制器。此注解键允许为某个命名空间分配容忍度,在这个命名空间中创建的所有新 Pod 都会被添加这些容忍度。
1089+
10711090
<!--
10721091
### scheduler.alpha.kubernetes.io/preferAvoidPods (deprecated) {#scheduleralphakubernetesio-preferavoidpods}
10731092
@@ -1414,9 +1433,9 @@ Used on: Pod
14141433
This annotation was only relevant if you were using [PodSecurityPolicies](/docs/concepts/security/pod-security-policy/).
14151434
Kubernetes v{{< skew currentVersion >}} does not support the PodSecurityPolicy API.
14161435
1417-
When the PodSecurityPolicy admission controller admits a Pod, the admission controller
1418-
modifies the Pod to have this annotation.
1419-
The value of the annotation is the name of the PodSecurityPolicy that was used for validation.
1436+
When the PodSecurityPolicy admission controller admitted a Pod, the admission controller
1437+
modified the Pod to have this annotation.
1438+
The value of the annotation was the name of the PodSecurityPolicy that was used for validation.
14201439
-->
14211440

14221441
### kubernetes.io/psp(已弃用) {#kubernetes-io-psp}
@@ -1428,8 +1447,7 @@ The value of the annotation is the name of the PodSecurityPolicy that was used f
14281447
这个注解只在你使用 [PodSecurityPolicies](/zh-cn/docs/concepts/security/pod-security-policy/) 时才有意义。
14291448
Kubernetes v{{< skew currentVersion >}} 不支持 PodSecurityPolicy API。
14301449

1431-
当 PodSecurityPolicy 准入控制器接受一个 Pod 时,会修改该 Pod,
1432-
并给这个 Pod 添加此注解。
1450+
当 PodSecurityPolicy 准入控制器接受一个 Pod 时,会修改该 Pod,并给这个 Pod 添加此注解。
14331451
注解的值是用来对 Pod 进行验证检查的 PodSecurityPolicy 的名称。
14341452

14351453
<!--
@@ -1453,7 +1471,7 @@ Pod 的 `.spec` 中的 [`securityContext`](/zh-cn/docs/reference/kubernetes-api/
14531471
你所给出的设置适用于该 Pod 中的所有容器。
14541472

14551473
<!--
1456-
### container.seccomp.security.alpha.kubernetes.io/[NAME] {#container-seccomp-security-alpha-kubernetes-io}
1474+
### container.seccomp.security.alpha.kubernetes.io/[NAME] (deprecated) {#container-seccomp-security-alpha-kubernetes-io}
14571475
14581476
This annotation has been deprecated since Kubernetes v1.19 and will become non-functional in a future release.
14591477
please use the corresponding pod or container `securityContext.seccompProfile` field instead.
@@ -1462,7 +1480,7 @@ you through the steps you follow to apply a seccomp profile to a Pod or to one o
14621480
its containers. That tutorial covers the supported mechanism for configuring seccomp in Kubernetes,
14631481
based on setting `securityContext` within the Pod's `.spec`.
14641482
-->
1465-
### container.seccomp.security.alpha.kubernetes.io/[NAME] {#container-seccomp-security-alpha-kubernetes-io}
1483+
### container.seccomp.security.alpha.kubernetes.io/[NAME] (已弃用){#container-seccomp-security-alpha-kubernetes-io}
14661484

14671485
此注解自 Kubernetes v1.19 起已被弃用,将在未来的版本中失效。
14681486
请使用对应 Pod 或容器的 `securityContext.seccompProfile` 字段替代。
@@ -1483,12 +1501,16 @@ Used on: VolumeSnapshotContent
14831501
<!--
14841502
Value can either be `true` or `false`.
14851503
This determines whether a user can modify the mode of the source volume when a
1486-
{{< glossary_tooltip text="PersistentVolumeClaim" term_id="persistent-volume-claim" >}} is being created from a VolumeSnapshot.
1487-
Refer to [Converting the volume mode of a Snapshot](/docs/concepts/storage/volume-snapshots/#convert-volume-mode) and the [Kubernetes CSI Developer Documentation](https://kubernetes-csi.github.io/docs/) for more information.
1504+
{{< glossary_tooltip text="PersistentVolumeClaim" term_id="persistent-volume-claim" >}} is being
1505+
created from a VolumeSnapshot.
1506+
1507+
Refer to [Converting the volume mode of a Snapshot](/docs/concepts/storage/volume-snapshots/#convert-volume-mode)
1508+
and the [Kubernetes CSI Developer Documentation](https://kubernetes-csi.github.io/docs/) for more information.
14881509
-->
14891510
值可以是 `true` 或者 `false`
14901511
这决定了当从 VolumeSnapshot 创建 {{< glossary_tooltip text="PersistentVolumeClaim" term_id="persistent-volume-claim" >}}
14911512
时,用户是否可以修改源卷的模式。
1513+
14921514
更多信息请参阅[转换快照的卷模式](/zh-cn/docs/concepts/storage/volume-snapshots/#convert-volume-mode)
14931515
[Kubernetes CSI 开发者文档](https://kubernetes-csi.github.io/docs/)
14941516

@@ -1525,6 +1547,7 @@ See more details on the [Audit Annotations](/docs/reference/labels-annotations-t
15251547

15261548
<!--
15271549
Example: `kubeadm.alpha.kubernetes.io/cri-socket: unix:///run/containerd/container.sock`
1550+
15281551
Used on: Node
15291552
-->
15301553
例子:`kubeadm.alpha.kubernetes.io/cri-socket: unix:///run/containerd/container.sock`
@@ -1533,7 +1556,8 @@ Used on: Node
15331556

15341557
<!--
15351558
Annotation that kubeadm uses to preserve the CRI socket information given to kubeadm at `init`/`join` time for later use.
1536-
kubeadm annotates the Node object with this information. The annotation remains "alpha", since ideally this should be a field in KubeletConfiguration instead.
1559+
kubeadm annotates the Node object with this information. The annotation remains "alpha", since ideally this should
1560+
be a field in KubeletConfiguration instead.
15371561
-->
15381562
kubeadm 用来保存 `init`/`join` 时提供给 kubeadm 以后使用的 CRI 套接字信息的注解。
15391563
kubeadm 使用此信息为 Node 对象设置注解。
@@ -1550,7 +1574,8 @@ Used on: Pod
15501574
用于:Pod
15511575

15521576
<!--
1553-
Annotation that kubeadm places on locally managed etcd pods to keep track of a list of URLs where etcd clients should connect to. This is used mainly for etcd cluster health check purposes.
1577+
Annotation that kubeadm places on locally managed etcd pods to keep track of a list of URLs where etcd clients
1578+
should connect to. This is used mainly for etcd cluster health check purposes.
15541579
-->
15551580
kubeadm 为本地管理的 etcd Pod 设置的注解,用来跟踪 etcd 客户端应连接到的 URL 列表。
15561581
这主要用于 etcd 集群健康检查目的。
@@ -1559,29 +1584,33 @@ kubeadm 为本地管理的 etcd Pod 设置的注解,用来跟踪 etcd 客户
15591584

15601585
<!--
15611586
Example: `kubeadm.kubernetes.io/kube-apiserver.advertise-address.endpoint: https//172.17.0.18:6443`
1587+
15621588
Used on: Pod
15631589
-->
15641590
例子:`kubeadm.kubernetes.io/kube-apiserver.advertise-address.endpoint: https//172.17.0.18:6443`
15651591

15661592
用于:Pod
15671593

15681594
<!--
1569-
Annotation that kubeadm places on locally managed kube-apiserver pods to keep track of the exposed advertise address/port endpoint for that API server instance.
1595+
Annotation that kubeadm places on locally managed kube-apiserver pods to keep track of the exposed advertise
1596+
address/port endpoint for that API server instance.
15701597
-->
15711598
kubeadm 为本地管理的 kube-apiserver Pod 设置的注解,用以跟踪该 API 服务器实例的公开宣告地址/端口端点。
15721599

15731600
### kubeadm.kubernetes.io/component-config.hash {#component-config-hash}
15741601

15751602
<!--
15761603
Used on: ConfigMap
1604+
15771605
Example: `kubeadm.kubernetes.io/component-config.hash: 2c26b46b68ffc68ff99b453c1d30413413422d706483bfa0f98a5e886266e7ae`
15781606
-->
15791607
例子:`kubeadm.kubernetes.io/component-config.hash: 2c26b46b68ffc68ff99b453c1d30413413422d706483bfa0f98a5e886266e7ae`
15801608

15811609
用于:ConfigMap
15821610

15831611
<!--
1584-
Annotation that kubeadm places on ConfigMaps that it manages for configuring components. It contains a hash (SHA-256) used to determine if the user has applied settings different from the kubeadm defaults for a particular component.
1612+
Annotation that kubeadm places on ConfigMaps that it manages for configuring components. It contains a hash (SHA-256)
1613+
used to determine if the user has applied settings different from the kubeadm defaults for a particular component.
15851614
-->
15861615
kubeadm 为它所管理的 ConfigMaps 设置的注解,用于配置组件。它包含一个哈希(SHA-256)值,
15871616
用于确定用户是否应用了不同于特定组件的 kubeadm 默认设置的设置。
@@ -1597,18 +1626,40 @@ Label that kubeadm applies on the control plane nodes that it manages.
15971626

15981627
kubeadm 在其管理的控制平面节点上应用的标签。
15991628

1600-
### node-role.kubernetes.io/control-plane
1629+
### node-role.kubernetes.io/control-plane {#node-role-kubernetes-io-control-plane-taint}
16011630

16021631
<!--
16031632
Used on: Node
16041633
16051634
Example: `node-role.kubernetes.io/control-plane:NoSchedule`
16061635
-->
1607-
例子:`node-role.kubernetes.io/control-plane:NoSchedule`
1608-
16091636
用于:Node
16101637

1638+
例子:`node-role.kubernetes.io/control-plane:NoSchedule`
1639+
16111640
<!--
16121641
Taint that kubeadm applies on control plane nodes to allow only critical workloads to schedule on them.
16131642
-->
16141643
kubeadm 应用在控制平面节点上的污点,仅允许在其上调度关键工作负载。
1644+
1645+
<!--
1646+
### node-role.kubernetes.io/master (deprecated) {#node-role-kubernetes-io-master-taint}
1647+
1648+
Used on: Node
1649+
1650+
Example: `node-role.kubernetes.io/master:NoSchedule`
1651+
1652+
Taint that kubeadm previously applied on control plane nodes to allow only critical workloads to schedule on them.
1653+
Replaced by [`node-role.kubernetes.io/control-plane`](#node-role-kubernetes-io-control-plane-taint); kubeadm
1654+
no longer sets or uses this deprecated taint.
1655+
-->
1656+
### node-role.kubernetes.io/master(已弃用) {#node-role-kubernetes-io-master-taint}
1657+
1658+
用于:Node
1659+
1660+
例子:`node-role.kubernetes.io/master:NoSchedule`
1661+
1662+
kubeadm 先前应用在控制平面节点上的污点,仅允许在其上调度关键工作负载。
1663+
替换为 [`node-role.kubernetes.io/control-plane`](#node-role-kubernetes-io-control-plane-taint)
1664+
kubeadm 不再设置或使用这个废弃的污点。
1665+

0 commit comments

Comments
 (0)