From 4b5c53fddf3d5ca27a2a4ad92b911b4eb41e8139 Mon Sep 17 00:00:00 2001
From: Josh Berkus
Date: Thu, 13 Jan 2022 17:45:40 -0800
Subject: [PATCH 001/331] Fix link to dev@kubernetes mailing list.
Signed-off-by: Josh Berkus
---
content/ru/docs/setup/learning-environment/minikube.md | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/content/ru/docs/setup/learning-environment/minikube.md b/content/ru/docs/setup/learning-environment/minikube.md
index 500d171abe..fea7e14252 100644
--- a/content/ru/docs/setup/learning-environment/minikube.md
+++ b/content/ru/docs/setup/learning-environment/minikube.md
@@ -525,6 +525,4 @@ Minikube использует [libmachine](https://github.com/docker/machine/tre
## Сообщество
-Помощь, вопросы и комментарии приветствуются и поощряются! Разработчики Minikube проводят время на [Slack](https://kubernetes.slack.com) в канале #minikube (получить приглашение можно [здесь](http://slack.kubernetes.io/)). У нас также есть [список рассылки kubernetes-dev на Google Groups](https://groups.google.com/forum/#!forum/kubernetes-dev). Если вы отправляете сообщение в список, пожалуйста, начните вашу тему с "minikube: ".
-
-
+Помощь, вопросы и комментарии приветствуются и поощряются! Разработчики Minikube проводят время на [Slack](https://kubernetes.slack.com) в канале #minikube (получить приглашение можно [здесь](http://slack.kubernetes.io/)). У нас также есть [список рассылки dev@kubernetes на Google Groups](https://groups.google.com/a/kubernetes.io/g/dev/). Если вы отправляете сообщение в список, пожалуйста, начните вашу тему с "minikube: ".
From 809ce2f54a8cc18cec66b34057910b27b3d33667 Mon Sep 17 00:00:00 2001
From: chrismetz09
Date: Mon, 7 Feb 2022 14:58:33 -0800
Subject: [PATCH 002/331] Add figure to text/caption _index.md
Change file: ../docs/contribute/_index.md
Method described in [How to use captions](https://kubernetes.io/docs/contribute/style/diagram-guide/#how-to-use-captions)
Contributes to common method for referencing and labeling figures in docs.
---
content/en/docs/contribute/_index.md | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/content/en/docs/contribute/_index.md b/content/en/docs/contribute/_index.md
index 9c48566ccd..7aec439fec 100644
--- a/content/en/docs/contribute/_index.md
+++ b/content/en/docs/contribute/_index.md
@@ -95,9 +95,9 @@ class A,B,C,D,E,F,G,H,M,Q,N,O,P,V grey
class S,T,U spacewhite
class first,second,third white
{{ mermaid >}}
-***Figure - Getting started for a new contributor***
+Figure 1. Getting started for a new contributor
-The figure above outlines a roadmap for new contributors. You can follow some or all of the steps for `Sign up` and `Review`. Now you are ready to open PRs that achieve your contribution objectives with some listed under `Open PR`. Again, questions are always welcome!
+Figure 1 outlines a roadmap for new contributors. You can follow some or all of the steps for `Sign up` and `Review`. Now you are ready to open PRs that achieve your contribution objectives with some listed under `Open PR`. Again, questions are always welcome!
Some tasks require more trust and more access in the Kubernetes organization.
See [Participating in SIG Docs](/docs/contribute/participate/) for more details about
@@ -105,7 +105,7 @@ roles and permissions.
## Your first contribution
-You can prepare for your first contribution by reviewing several steps beforehand. The figure below outlines the steps and the details follow.
+You can prepare for your first contribution by reviewing several steps beforehand. Figure 2 outlines the steps and the details follow.
@@ -136,7 +136,7 @@ class A,B,D,E,F,G grey
class S,T spacewhite
class first,second white
{{ mermaid >}}
-***Figure - Preparation for your first contribution***
+Figure 2. Preparation for your first contribution
- Read the [Contribution overview](/docs/contribute/new-content/overview/) to
learn about the different ways you can contribute.
From 72d99dfae643b3ae7cafb573d7f516d8cbb86bca Mon Sep 17 00:00:00 2001
From: chrismetz09
Date: Mon, 7 Feb 2022 15:16:37 -0800
Subject: [PATCH 003/331] add period to caption text
---
content/en/docs/contribute/_index.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/content/en/docs/contribute/_index.md b/content/en/docs/contribute/_index.md
index 7aec439fec..61a4e0a118 100644
--- a/content/en/docs/contribute/_index.md
+++ b/content/en/docs/contribute/_index.md
@@ -95,7 +95,7 @@ class A,B,C,D,E,F,G,H,M,Q,N,O,P,V grey
class S,T,U spacewhite
class first,second,third white
{{ mermaid >}}
-Figure 1. Getting started for a new contributor
+Figure 1. Getting started for a new contributor.
Figure 1 outlines a roadmap for new contributors. You can follow some or all of the steps for `Sign up` and `Review`. Now you are ready to open PRs that achieve your contribution objectives with some listed under `Open PR`. Again, questions are always welcome!
@@ -136,7 +136,7 @@ class A,B,D,E,F,G grey
class S,T spacewhite
class first,second white
{{ mermaid >}}
-Figure 2. Preparation for your first contribution
+Figure 2. Preparation for your first contribution.
- Read the [Contribution overview](/docs/contribute/new-content/overview/) to
learn about the different ways you can contribute.
From d05fb625f4e0f70279456eb2cbf50b73daf31f43 Mon Sep 17 00:00:00 2001
From: Martin Tovmassian
Date: Tue, 8 Mar 2022 16:54:48 +0100
Subject: [PATCH 004/331] [en] Update Bash alias auto-completion
---
content/en/docs/reference/kubectl/cheatsheet.md | 2 +-
.../tasks/tools/included/optional-kubectl-configs-bash-linux.md | 2 +-
.../tasks/tools/included/optional-kubectl-configs-bash-mac.md | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/content/en/docs/reference/kubectl/cheatsheet.md b/content/en/docs/reference/kubectl/cheatsheet.md
index 8d995efb49..8be170b5f2 100644
--- a/content/en/docs/reference/kubectl/cheatsheet.md
+++ b/content/en/docs/reference/kubectl/cheatsheet.md
@@ -30,7 +30,7 @@ You can also use a shorthand alias for `kubectl` that also works with completion
```bash
alias k=kubectl
-complete -F __start_kubectl k
+complete -o default -F __start_kubectl k
```
### ZSH
diff --git a/content/en/docs/tasks/tools/included/optional-kubectl-configs-bash-linux.md b/content/en/docs/tasks/tools/included/optional-kubectl-configs-bash-linux.md
index 0024ff8bbc..8a5889b813 100644
--- a/content/en/docs/tasks/tools/included/optional-kubectl-configs-bash-linux.md
+++ b/content/en/docs/tasks/tools/included/optional-kubectl-configs-bash-linux.md
@@ -43,7 +43,7 @@ If you have an alias for kubectl, you can extend shell completion to work with t
```bash
echo 'alias k=kubectl' >>~/.bashrc
-echo 'complete -F __start_kubectl k' >>~/.bashrc
+echo 'complete -o default -F __start_kubectl k' >>~/.bashrc
```
{{< note >}}
diff --git a/content/en/docs/tasks/tools/included/optional-kubectl-configs-bash-mac.md b/content/en/docs/tasks/tools/included/optional-kubectl-configs-bash-mac.md
index 9854540649..47243c575a 100644
--- a/content/en/docs/tasks/tools/included/optional-kubectl-configs-bash-mac.md
+++ b/content/en/docs/tasks/tools/included/optional-kubectl-configs-bash-mac.md
@@ -77,7 +77,7 @@ You now have to ensure that the kubectl completion script gets sourced in all yo
```bash
echo 'alias k=kubectl' >>~/.bash_profile
- echo 'complete -F __start_kubectl k' >>~/.bash_profile
+ echo 'complete -o default -F __start_kubectl k' >>~/.bash_profile
```
- If you installed kubectl with Homebrew (as explained [here](/docs/tasks/tools/install-kubectl-macos/#install-with-homebrew-on-macos)), then the kubectl completion script should already be in `/usr/local/etc/bash_completion.d/kubectl`. In that case, you don't need to do anything.
From fdfc64e861e36fbe6e28f3801bca84c2b54d6ab6 Mon Sep 17 00:00:00 2001
From: sgpinkus
Date: Sat, 19 Mar 2022 13:17:50 +1100
Subject: [PATCH 005/331] Update _index.md
Make 100% clear, that according to the k8s networking model pods are supposed to get their own unique IP address. I always thought this was the case. But then faced debugging issue where some pods are being assigned the same IP addresses. Came here to review my understanding of it, and confirm this is expected behaviour or not. But it was not stated unequivocally. This change makes it so.
---
.../docs/concepts/services-networking/_index.md | 15 +++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/content/en/docs/concepts/services-networking/_index.md b/content/en/docs/concepts/services-networking/_index.md
index ab1b784658..2e443d4744 100644
--- a/content/en/docs/concepts/services-networking/_index.md
+++ b/content/en/docs/concepts/services-networking/_index.md
@@ -7,26 +7,25 @@ description: >
## The Kubernetes network model
-Every [`Pod`](/docs/concepts/workloads/pods/) gets its own IP address.
+Every [`Pod`](/docs/concepts/workloads/pods/) in a cluster gets its own unique cluster wide IP address.
This means you do not need to explicitly create links between `Pods` and you
almost never need to deal with mapping container ports to host ports.
This creates a clean, backwards-compatible model where `Pods` can be treated
much like VMs or physical hosts from the perspectives of port allocation,
-naming, service discovery, [load balancing](/docs/concepts/services-networking/ingress/#load-balancing), application configuration,
-and migration.
+naming, service discovery, [load balancing](/docs/concepts/services-networking/ingress/#load-balancing),
+application configuration, and migration.
Kubernetes imposes the following fundamental requirements on any networking
implementation (barring any intentional network segmentation policies):
- * pods on a [node](/docs/concepts/architecture/nodes/) can communicate with all pods on all nodes without NAT
+ * pods can communicate with all other pods on any other [node](/docs/concepts/architecture/nodes/)
+ without NAT
* agents on a node (e.g. system daemons, kubelet) can communicate with all
pods on that node
Note: For those platforms that support `Pods` running in the host network (e.g.
-Linux):
-
- * pods in the host network of a node can communicate with all pods on all
- nodes without NAT
+Linux), when pods are attached to the host network of a node they can still communicate
+with all pods on all nodes without NAT.
This model is not only less complex overall, but it is principally compatible
with the desire for Kubernetes to enable low-friction porting of apps from VMs
From 417eede9858a94fc8f2dec5cf03b7e7cd7566229 Mon Sep 17 00:00:00 2001
From: sgpinkus
Date: Mon, 21 Mar 2022 21:01:49 +1100
Subject: [PATCH 006/331] Update
content/en/docs/concepts/services-networking/_index.md
Co-authored-by: divya-mohan0209
---
content/en/docs/concepts/services-networking/_index.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/en/docs/concepts/services-networking/_index.md b/content/en/docs/concepts/services-networking/_index.md
index 2e443d4744..b4f7861075 100644
--- a/content/en/docs/concepts/services-networking/_index.md
+++ b/content/en/docs/concepts/services-networking/_index.md
@@ -7,7 +7,7 @@ description: >
## The Kubernetes network model
-Every [`Pod`](/docs/concepts/workloads/pods/) in a cluster gets its own unique cluster wide IP address.
+Every [`Pod`](/docs/concepts/workloads/pods/) in a cluster gets its own unique cluster-wide IP address.
This means you do not need to explicitly create links between `Pods` and you
almost never need to deal with mapping container ports to host ports.
This creates a clean, backwards-compatible model where `Pods` can be treated
From c9ef193727559aef2a12f17d815af9dd47bc14cb Mon Sep 17 00:00:00 2001
From: Tim Allclair
Date: Wed, 13 Apr 2022 17:06:54 -0700
Subject: [PATCH 007/331] [pt-br] Clean up various broken links
---
content/pt-br/docs/concepts/cluster-administration/addons.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/content/pt-br/docs/concepts/cluster-administration/addons.md b/content/pt-br/docs/concepts/cluster-administration/addons.md
index f3a00ae26d..0e0175cace 100644
--- a/content/pt-br/docs/concepts/cluster-administration/addons.md
+++ b/content/pt-br/docs/concepts/cluster-administration/addons.md
@@ -21,7 +21,7 @@ Esta página lista alguns dos complementos disponíveis e links com suas respect
* [Canal](https://github.com/tigera/canal/tree/master/k8s-install) une Flannel e Calico, fornecendo rede e política de rede.
* [Cilium](https://github.com/cilium/cilium) é um plug-in de rede de camada 3 e de políticas de rede que pode aplicar políticas HTTP/API/camada 7 de forma transparente. Tanto o modo de roteamento quanto o de sobreposição/encapsulamento são suportados. Este plug-in também consegue operar no topo de outros plug-ins CNI.
* [CNI-Genie](https://github.com/Huawei-PaaS/CNI-Genie) permite que o Kubernetes se conecte facilmente a uma variedade de plug-ins CNI, como Calico, Canal, Flannel, Romana ou Weave.
-* [Contiv](http://contiv.github.io) oferece serviços de rede configuráveis para diferentes casos de uso (camada 3 nativa usando BGP, _overlay_ (sobreposição) usando vxlan, camada 2 clássica e Cisco-SDN/ACI) e também um _framework_ rico de políticas de rede. O projeto Contiv é totalmente [open source](http://github.com/contiv). O [instalador](http://github.com/contiv/install) fornece opções de instalação com ou sem kubeadm.
+* [Contiv](https://contivpp.io/) oferece serviços de rede configuráveis para diferentes casos de uso (camada 3 nativa usando BGP, _overlay_ (sobreposição) usando vxlan, camada 2 clássica e Cisco-SDN/ACI) e também um _framework_ rico de políticas de rede. O projeto Contiv é totalmente [open source](http://github.com/contiv). O [instalador](http://github.com/contiv/install) fornece opções de instalação com ou sem kubeadm.
* [Contrail](http://www.juniper.net/us/en/products-services/sdn/contrail/contrail-networking/) é uma plataforma open source baseada no [Tungsten Fabric](https://tungsten.io) que oferece virtualização de rede multi-nuvem e gerenciamento de políticas de rede. O Contrail e o Tungsten Fabric são integrados a sistemas de orquestração de contêineres, como Kubernetes, OpenShift, OpenStack e Mesos, e fornecem modos de isolamento para cargas de trabalho executando em máquinas virtuais, contêineres/pods e servidores físicos.
* [Flannel](https://github.com/flannel-io/flannel#deploying-flannel-manually) é um provedor de redes _overlay_ (sobrepostas) que pode ser usado com o Kubernetes.
* [Knitter](https://github.com/ZTE/Knitter/) é um plug-in para suporte de múltiplas interfaces de rede em Pods do Kubernetes.
@@ -30,7 +30,7 @@ Esta página lista alguns dos complementos disponíveis e links com suas respect
* [Nuage](https://github.com/nuagenetworks/nuage-kubernetes/blob/v5.1.1-1/docs/kubernetes-1-installation.rst) é uma plataforma de rede definida por software que fornece serviços de rede baseados em políticas entre os Pods do Kubernetes e os ambientes não-Kubernetes, com visibilidade e monitoramento de segurança.
* [OVN-Kubernetes](https://github.com/ovn-org/ovn-kubernetes/) é um provedor de rede para o Kubernetes baseado no [OVN (Open Virtual Network)](https://github.com/ovn-org/ovn/), uma implementação de redes virtuais que surgiu através do projeto Open vSwitch (OVS). O OVN-Kubernetes fornece uma implementação de rede baseada em _overlay_ (sobreposição) para o Kubernetes, incluindo uma implementação baseada em OVS para serviços de balanceamento de carga e políticas de rede.
* [OVN4NFV-K8S-Plugin](https://github.com/opnfv/ovn4nfv-k8s-plugin) é um plug-in controlador CNI baseado no OVN (Open Virtual Network) que fornece serviços de rede _cloud native_, como _Service Function Chaining_ (SFC), redes _overlay_ (sobrepostas) OVN múltiplas, criação dinâmica de subredes, criação dinâmica de redes virtuais, provedor de rede VLAN e provedor de rede direto, e é plugável a outros plug-ins multi-rede. Ideal para cargas de trabalho que utilizam computação de borda _cloud native_ em redes multi-cluster.
-* [Romana](http://romana.io) é uma solução de rede de camada 3 para redes de pods que também suporta a [API NetworkPolicy](/docs/concepts/services-networking/network-policies/). Detalhes da instalação do complemento Kubeadm disponíveis [aqui](https://github.com/romana/romana/tree/master/containerize).
+* [Romana](https://github.com/romana/romana) é uma solução de rede de camada 3 para redes de pods que também suporta a [API NetworkPolicy](/docs/concepts/services-networking/network-policies/). Detalhes da instalação do complemento Kubeadm disponíveis [aqui](https://github.com/romana/romana/tree/master/containerize).
* [Weave Net](https://www.weave.works/docs/net/latest/kube-addon/) fornece rede e política de rede, funciona em ambos os lados de uma partição de rede e não requer um banco de dados externo.
## Descoberta de Serviço
From f26337fadc73cbc4dbe37c376919e89f63801b8f Mon Sep 17 00:00:00 2001
From: s-kawamura-w664
Date: Fri, 25 Feb 2022 09:11:00 +0000
Subject: [PATCH 008/331] Add that pv's access modes are not constraints on the
volume.
---
content/en/docs/concepts/storage/persistent-volumes.md | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/content/en/docs/concepts/storage/persistent-volumes.md b/content/en/docs/concepts/storage/persistent-volumes.md
index 7a11939507..e7f4f52ce3 100644
--- a/content/en/docs/concepts/storage/persistent-volumes.md
+++ b/content/en/docs/concepts/storage/persistent-volumes.md
@@ -477,6 +477,15 @@ In the CLI, the access modes are abbreviated to:
* RWX - ReadWriteMany
* RWOP - ReadWriteOncePod
+{{< note >}}
+Kubernetes uses volume access modes to match PersistentVolumeClaims and PersistentVolumes.
+In some cases, the volume access modes also constrain where the PersistentVolume can be mounted.
+Volume access modes do **not** enforce write protection once the storage has been mounted.
+Even if the access modes are specified as ReadWriteOnce, ReadOnlyMany, or ReadWriteMany, they don't set any constraints on the volume.
+For example, even if a PersistentVolume is created as ReadOnlyMany, it is no guarantee that it will be read-only.
+If the access modes are specified as ReadWriteOncePod, the volume is constrained and can be mounted on only a single Pod.
+{{< /note >}}
+
> __Important!__ A volume can only be mounted using one access mode at a time, even if it supports many. For example, a GCEPersistentDisk can be mounted as ReadWriteOnce by a single node or ReadOnlyMany by many nodes, but not at the same time.
From 0322a37d80bc7e5e1b4e1a77cc38ee474fc6a4a1 Mon Sep 17 00:00:00 2001
From: Tim Bannister
Date: Thu, 14 Apr 2022 17:44:25 +0100
Subject: [PATCH 009/331] Update Romana details
- omit it as an example from CNI-Genie
- update the hyperlink
---
content/en/docs/concepts/cluster-administration/addons.md | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/content/en/docs/concepts/cluster-administration/addons.md b/content/en/docs/concepts/cluster-administration/addons.md
index 20626f2ff4..3e9cd31643 100644
--- a/content/en/docs/concepts/cluster-administration/addons.md
+++ b/content/en/docs/concepts/cluster-administration/addons.md
@@ -20,8 +20,7 @@ This page lists some of the available add-ons and links to their respective inst
* [Calico](https://docs.projectcalico.org/latest/introduction/) is a networking and network policy provider. Calico supports a flexible set of networking options so you can choose the most efficient option for your situation, including non-overlay and overlay networks, with or without BGP. Calico uses the same engine to enforce network policy for hosts, pods, and (if using Istio & Envoy) applications at the service mesh layer.
* [Canal](https://github.com/tigera/canal/tree/master/k8s-install) unites Flannel and Calico, providing networking and network policy.
* [Cilium](https://github.com/cilium/cilium) is a L3 network and network policy plugin that can enforce HTTP/API/L7 policies transparently. Both routing and overlay/encapsulation mode are supported, and it can work on top of other CNI plugins.
-* [CNI-Genie](https://github.com/Huawei-PaaS/CNI-Genie) enables Kubernetes to seamlessly connect to a choice of CNI plugins, such as Calico, Canal, Flannel, Romana, or Weave.
-* [Contiv](https://contivpp.io/) provides configurable networking (native L3 using BGP, overlay using vxlan, classic L2, and Cisco-SDN/ACI) for various use cases and a rich policy framework. Contiv project is fully [open sourced](https://github.com/contiv). The [installer](https://github.com/contiv/install) provides both kubeadm and non-kubeadm based installation options.
+* [CNI-Genie](https://github.com/Huawei-PaaS/CNI-Genie) enables Kubernetes to seamlessly connect to a choice of CNI plugins, such as Calico, Canal, Flannel, or Weave.
* [Contrail](https://www.juniper.net/us/en/products-services/sdn/contrail/contrail-networking/), based on [Tungsten Fabric](https://tungsten.io), is an open source, multi-cloud network virtualization and policy management platform. Contrail and Tungsten Fabric are integrated with orchestration systems such as Kubernetes, OpenShift, OpenStack and Mesos, and provide isolation modes for virtual machines, containers/pods and bare metal workloads.
* [Flannel](https://github.com/flannel-io/flannel#deploying-flannel-manually) is an overlay network provider that can be used with Kubernetes.
* [Knitter](https://github.com/ZTE/Knitter/) is a plugin to support multiple network interfaces in a Kubernetes pod.
@@ -30,7 +29,7 @@ This page lists some of the available add-ons and links to their respective inst
* [OVN4NFV-K8S-Plugin](https://github.com/opnfv/ovn4nfv-k8s-plugin) is OVN based CNI controller plugin to provide cloud native based Service function chaining(SFC), Multiple OVN overlay networking, dynamic subnet creation, dynamic creation of virtual networks, VLAN Provider network, Direct provider network and pluggable with other Multi-network plugins, ideal for edge based cloud native workloads in Multi-cluster networking
* [NSX-T](https://docs.vmware.com/en/VMware-NSX-T/2.0/nsxt_20_ncp_kubernetes.pdf) Container Plug-in (NCP) provides integration between VMware NSX-T and container orchestrators such as Kubernetes, as well as integration between NSX-T and container-based CaaS/PaaS platforms such as Pivotal Container Service (PKS) and OpenShift.
* [Nuage](https://github.com/nuagenetworks/nuage-kubernetes/blob/v5.1.1-1/docs/kubernetes-1-installation.rst) is an SDN platform that provides policy-based networking between Kubernetes Pods and non-Kubernetes environments with visibility and security monitoring.
-* **Romana** is a Layer 3 networking solution for pod networks that also supports the [NetworkPolicy API](/docs/concepts/services-networking/network-policies/). Kubeadm add-on installation details available [here](https://github.com/romana/romana/tree/master/containerize).
+* [Romana](https://github.com/romana) is a Layer 3 networking solution for pod networks that also supports the [NetworkPolicy](/docs/concepts/services-networking/network-policies/) API.
* [Weave Net](https://www.weave.works/docs/net/latest/kubernetes/kube-addon/) provides networking and network policy, will carry on working on both sides of a network partition, and does not require an external database.
## Service Discovery
From bf0c2cfcf7f55b4571aef80fd6bd8d54330f8b1e Mon Sep 17 00:00:00 2001
From: Joel Gerber
Date: Thu, 21 Apr 2022 11:35:46 -0400
Subject: [PATCH 010/331] Fix a minor typo in the 2nd paragraph of overview
---
content/en/docs/reference/using-api/api-concepts.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/en/docs/reference/using-api/api-concepts.md b/content/en/docs/reference/using-api/api-concepts.md
index 2e4fb85df2..a458cdff2d 100644
--- a/content/en/docs/reference/using-api/api-concepts.md
+++ b/content/en/docs/reference/using-api/api-concepts.md
@@ -15,7 +15,7 @@ primary resources via the standard HTTP verbs (POST, PUT, PATCH, DELETE,
GET).
For some resources, the API includes additional subresources that allow
-fine grained authorization (such as a separating viewing details for a Pod from
+fine grained authorization (such as separating viewing details for a Pod from
retrieving its logs), and can accept and serve those resources in different
representations for convenience or efficiency.
From f22d7fa961b4ac229d83f769f2acf670c542ea53 Mon Sep 17 00:00:00 2001
From: "Mr. Erlison"
Date: Thu, 21 Apr 2022 13:32:11 -0300
Subject: [PATCH 011/331] Add
content/pt-br/docs/reference/glossary/applications.md
---
.../pt-br/docs/reference/glossary/applications.md | 12 ++++++++++++
1 file changed, 12 insertions(+)
create mode 100644 content/pt-br/docs/reference/glossary/applications.md
diff --git a/content/pt-br/docs/reference/glossary/applications.md b/content/pt-br/docs/reference/glossary/applications.md
new file mode 100644
index 0000000000..a00ca0ec6c
--- /dev/null
+++ b/content/pt-br/docs/reference/glossary/applications.md
@@ -0,0 +1,12 @@
+---
+title: Aplicações
+id: applications
+date: 2019-05-12
+full_link:
+short_description: >
+ A camada onde vários aplicativos em contêiner são executados.
+aka:
+tags:
+- fundamental
+---
+ A camada onde vários aplicativos em contêiner são executados.
From aaeaddba63bcbde54893b87c36c795e73b6d34dd Mon Sep 17 00:00:00 2001
From: "Mr. Erlison"
Date: Thu, 21 Apr 2022 13:38:19 -0300
Subject: [PATCH 012/331] Add
content/pt-br/docs/reference/glossary/certificate.md
---
.../docs/reference/glossary/certificate.md | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
create mode 100644 content/pt-br/docs/reference/glossary/certificate.md
diff --git a/content/pt-br/docs/reference/glossary/certificate.md b/content/pt-br/docs/reference/glossary/certificate.md
new file mode 100644
index 0000000000..d43ead1f32
--- /dev/null
+++ b/content/pt-br/docs/reference/glossary/certificate.md
@@ -0,0 +1,17 @@
+---
+title: Certificado
+id: certificate
+date: 2018-04-12
+full_link: /docs/tasks/tls/managing-tls-in-a-cluster/
+short_description: >
+ Um arquivo criptograficamente seguro usado para validar o acesso ao cluster Kubernetes.
+
+aka:
+tags:
+- security
+---
+ Um arquivo criptograficamente seguro usado para validar o acesso ao cluster Kubernetes.
+
+
+
+Os certificados permitem que aplicativos dentro de um cluster Kubernetes acessem a API do Kubernetes com segurança. Os certificados validam que os clientes têm permissão para acessar a API.
\ No newline at end of file
From d9043dd29b5920fd4ec91a7c3a733fc538a3de48 Mon Sep 17 00:00:00 2001
From: "Mr. Erlison"
Date: Thu, 21 Apr 2022 13:44:17 -0300
Subject: [PATCH 013/331] content/pt-br/docs/reference/glossary/cidr.md
---
content/pt-br/docs/reference/glossary/cidr.md | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
create mode 100644 content/pt-br/docs/reference/glossary/cidr.md
diff --git a/content/pt-br/docs/reference/glossary/cidr.md b/content/pt-br/docs/reference/glossary/cidr.md
new file mode 100644
index 0000000000..3073e6560c
--- /dev/null
+++ b/content/pt-br/docs/reference/glossary/cidr.md
@@ -0,0 +1,17 @@
+---
+title: CIDR
+id: cidr
+date: 2019-11-12
+full_link:
+short_description: >
+ CIDR é uma notação para descrever blocos de endereços IP e é muito usada em várias configurações de rede.
+
+aka:
+tags:
+- networking
+---
+CIDR (em inglês - Classless Inter-Domain Routing) é uma notação para descrever blocos de endereços IP e é muito usada em várias configurações de rede.
+
+
+
+No contexto do Kubernetes, cada {{< glossary_tooltip text="Nó" term_id="node" >}} recebe um intervalo de endereços IP através do endereço inicial e uma máscara de sub-rede usando CIDR. Isso permite que os Nodes atribuam a cada {{< glossary_tooltip text="Pod" term_id="pod" >}} um endereço IP exclusivo. Embora originalmente seja um conceito para IPv4, o CIDR também foi expandido para incluir IPv6.
\ No newline at end of file
From 688060dcc9c67f932d8fde43db51213e4d0277f6 Mon Sep 17 00:00:00 2001
From: "Mr. Erlison"
Date: Thu, 21 Apr 2022 13:55:23 -0300
Subject: [PATCH 014/331] Add
content/pt-br/docs/reference/glossary/cluster-architect.md
---
.../reference/glossary/cluster-architect.md | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
create mode 100644 content/pt-br/docs/reference/glossary/cluster-architect.md
diff --git a/content/pt-br/docs/reference/glossary/cluster-architect.md b/content/pt-br/docs/reference/glossary/cluster-architect.md
new file mode 100644
index 0000000000..3aeb95e084
--- /dev/null
+++ b/content/pt-br/docs/reference/glossary/cluster-architect.md
@@ -0,0 +1,17 @@
+---
+title: Arquiteto de Cluster
+id: cluster-architect
+date: 2018-04-12
+full_link:
+short_description: >
+ Uma pessoa que projeta infraestrutura que envolve um ou mais clusters Kubernetes.
+
+aka:
+tags:
+- user-type
+---
+ Uma pessoa que projeta infraestrutura que envolve um ou mais clusters Kubernetes.
+
+
+
+Os arquitetos de clusters estão preocupados com as melhores práticas para sistemas distribuídos, por exemplo: alta disponibilidade e segurança.
\ No newline at end of file
From 317f1e6eb90d7d5f04973cf847eabe90fc2e2e6f Mon Sep 17 00:00:00 2001
From: "Mr. Erlison"
Date: Thu, 21 Apr 2022 14:01:13 -0300
Subject: [PATCH 015/331] Add
content/pt-br/docs/reference/glossary/volume-plugin.md
---
.../docs/reference/glossary/volume-plugin.md | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
create mode 100644 content/pt-br/docs/reference/glossary/volume-plugin.md
diff --git a/content/pt-br/docs/reference/glossary/volume-plugin.md b/content/pt-br/docs/reference/glossary/volume-plugin.md
new file mode 100644
index 0000000000..1936fdf3f2
--- /dev/null
+++ b/content/pt-br/docs/reference/glossary/volume-plugin.md
@@ -0,0 +1,18 @@
+---
+title: Plugin de Volume
+id: volumeplugin
+date: 2018-04-12
+full_link:
+short_description: >
+ Um plugin de volume permite a integração do armazenamento dentro de um Pod.
+
+aka:
+tags:
+- core-object
+- storage
+---
+ Um plugin de volume permite a integração do armazenamento dentro de um {{< glossary_tooltip text="Pod" term_id="pod" >}}.
+
+
+
+Um plugin de volume permite anexar e montar volumes de armazenamento para uso por um {{< glossary_tooltip text="Pod" term_id="pod" >}}. Os plugins de volume podem estar _dentro_ ou _fora da árvore_. _Na árvore_, os plugins fazem parte do repositório de código Kubernetes e seguem seu ciclo de lançamento. Os plugins _fora da árvore_ são desenvolvidos de forma independente.
\ No newline at end of file
From 69a3fc37750e7d72712fcbd09a42dcbb694cc62f Mon Sep 17 00:00:00 2001
From: "Mr. Erlison"
Date: Thu, 21 Apr 2022 14:47:45 -0300
Subject: [PATCH 016/331] Add content/pt-br/docs/reference/glossary/reviewer.md
---
.../pt-br/docs/reference/glossary/reviewer.md | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
create mode 100644 content/pt-br/docs/reference/glossary/reviewer.md
diff --git a/content/pt-br/docs/reference/glossary/reviewer.md b/content/pt-br/docs/reference/glossary/reviewer.md
new file mode 100644
index 0000000000..ff367087ee
--- /dev/null
+++ b/content/pt-br/docs/reference/glossary/reviewer.md
@@ -0,0 +1,17 @@
+---
+title: Revisor
+id: reviewer
+date: 2018-04-12
+full_link:
+short_description: >
+ Uma pessoa que revisa o código quanto à qualidade e correção em alguma parte do projeto.
+
+aka:
+tags:
+- community
+---
+ Uma pessoa que revisa o código quanto à qualidade e correção em alguma parte do projeto.
+
+
+
+Os revisores têm conhecimento sobre o código base e os princípios de engenharia de software. O estado do revisor é atribuído a uma parte do código.
\ No newline at end of file
From f3adb2cd66aea0aed3d5d78f90da46409bac0ffb Mon Sep 17 00:00:00 2001
From: Joel Gerber
Date: Fri, 22 Apr 2022 07:06:31 -0400
Subject: [PATCH 017/331] Update
content/en/docs/reference/using-api/api-concepts.md
Co-authored-by: divya-mohan0209
---
content/en/docs/reference/using-api/api-concepts.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/en/docs/reference/using-api/api-concepts.md b/content/en/docs/reference/using-api/api-concepts.md
index a458cdff2d..a7a8f1d059 100644
--- a/content/en/docs/reference/using-api/api-concepts.md
+++ b/content/en/docs/reference/using-api/api-concepts.md
@@ -15,7 +15,7 @@ primary resources via the standard HTTP verbs (POST, PUT, PATCH, DELETE,
GET).
For some resources, the API includes additional subresources that allow
-fine grained authorization (such as separating viewing details for a Pod from
+fine grained authorization (such as separate viewing details for a Pod from
retrieving its logs), and can accept and serve those resources in different
representations for convenience or efficiency.
From 89b0b1bf8f72ab16fbdd3ad82ff9679d25b40d11 Mon Sep 17 00:00:00 2001
From: Qiming Teng
Date: Sat, 23 Apr 2022 14:30:14 +0800
Subject: [PATCH 018/331] Move kubelet authentication/authorization out of CLI
reference dir
The `kubelet-authentication-authorization` and the `kubelet-tls-bootstrapping`
pages do not belong to `reference/command-line-tools-reference` topic.
This PR moves them into `reference/access-authn-authz` subdirectory
which is a better fit.
The `static/_redirects` file is updated to point to the new location.
---
content/en/docs/reference/access-authn-authz/_index.md | 2 ++
.../kubelet-authn-authz.md} | 0
.../kubelet-tls-bootstrapping.md | 0
static/_redirects | 6 +++---
4 files changed, 5 insertions(+), 3 deletions(-)
rename content/en/docs/reference/{command-line-tools-reference/kubelet-authentication-authorization.md => access-authn-authz/kubelet-authn-authz.md} (100%)
rename content/en/docs/reference/{command-line-tools-reference => access-authn-authz}/kubelet-tls-bootstrapping.md (100%)
diff --git a/content/en/docs/reference/access-authn-authz/_index.md b/content/en/docs/reference/access-authn-authz/_index.md
index 86d06488a8..3677f79c57 100644
--- a/content/en/docs/reference/access-authn-authz/_index.md
+++ b/content/en/docs/reference/access-authn-authz/_index.md
@@ -24,3 +24,5 @@ Reference documentation:
- Service accounts
- [Developer guide](/docs/tasks/configure-pod-container/configure-service-account/)
- [Administration](/docs/reference/access-authn-authz/service-accounts-admin/)
+- [Kubelet Authentication & Authorization](/docs/reference/access-authn-authz/kubelet-authn-authz/)
+ - including kubelet [TLS bootstrapping](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/)
diff --git a/content/en/docs/reference/command-line-tools-reference/kubelet-authentication-authorization.md b/content/en/docs/reference/access-authn-authz/kubelet-authn-authz.md
similarity index 100%
rename from content/en/docs/reference/command-line-tools-reference/kubelet-authentication-authorization.md
rename to content/en/docs/reference/access-authn-authz/kubelet-authn-authz.md
diff --git a/content/en/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping.md b/content/en/docs/reference/access-authn-authz/kubelet-tls-bootstrapping.md
similarity index 100%
rename from content/en/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping.md
rename to content/en/docs/reference/access-authn-authz/kubelet-tls-bootstrapping.md
diff --git a/static/_redirects b/static/_redirects
index bb17b4d01a..c0feadd2bd 100644
--- a/static/_redirects
+++ b/static/_redirects
@@ -41,8 +41,8 @@
/docs/admin/ha-master-gce/ /docs/setup/production-environment/#production-control-plane 301
/docs/admin/ha-master-gce.md/ /docs/setup/production-environment/#production-control-plane 301
/docs/admin/high-availability/ /docs/setup/production-environment/tools/kubeadm/high-availability/ 301
-/docs/admin/kubelet-authentication-authorization/ /docs/reference/command-line-tools-reference/kubelet-authentication-authorization/ 301
-/docs/admin/kubelet-tls-bootstrapping/ /docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/ 301
+/docs/admin/kubelet-authentication-authorization/ /docs/reference/access-authn-authz/kubelet-authn-authz/ 301
+/docs/admin/kubelet-tls-bootstrapping/ /docs/reference/access-authn-authz/kubelet-tls-bootstrapping/ 301
/docs/admin/limitrange/ /docs/tasks/administer-cluster/cpu-memory-limit/ 301
/docs/admin/limitrange/Limits/ /docs/tasks/administer-cluster/limit-storage-consumption/#limitrange-to-limit-requests-for-storage/ 301
/docs/admin/master-node-communication/ /docs/concepts/architecture/master-node-communication/ 301
@@ -250,7 +250,7 @@
/docs/tasks/administer-cluster/apply-resource-quota-limit/ /docs/tasks/administer-cluster/quota-api-object/ 301
/docs/tasks/administer-cluster/assign-pods-nodes/ /docs/tasks/configure-pod-container/assign-pods-nodes/ 301
/docs/tasks/administer-cluster/calico-network-policy/ /docs/tasks/administer-cluster/network-policy-provider/calico-network-policy/ 301
-/docs/tasks/administer-cluster/certificate-rotation/ /docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/ 301
+/docs/tasks/administer-cluster/certificate-rotation/ /docs/reference/access-authn-authz/kubelet-tls-bootstrapping/ 301
/docs/tasks/administer-cluster/cilium-network-policy/ /docs/tasks/administer-cluster/network-policy-provider/cilium-network-policy/ 301
/docs/tasks/administer-cluster/configure-namespace-isolation/ /docs/concepts/services-networking/network-policies/ 301
/docs/tasks/administer-cluster/configure-multiple-schedulers/ /docs/tasks/extend-kubernetes/configure-multiple-schedulers/ 301
From a3ea9f4caf30794129ff790dced758701b0332ed Mon Sep 17 00:00:00 2001
From: Qiming Teng
Date: Sat, 23 Apr 2022 14:32:19 +0800
Subject: [PATCH 019/331] Update references to the kubelet security files
This commit updates all the existing references to the files move in the previous commit.
---
.../architecture/control-plane-node-communication.md | 4 ++--
.../en/docs/concepts/cluster-administration/_index.md | 4 ++--
.../reference/access-authn-authz/bootstrap-tokens.md | 2 +-
content/en/docs/reference/access-authn-authz/node.md | 2 +-
content/en/docs/reference/access-authn-authz/rbac.md | 2 +-
.../command-line-tools-reference/feature-gates.md | 4 ++--
.../setup-tools/kubeadm/implementation-details.md | 4 ++--
.../reference/setup-tools/kubeadm/kubeadm-init.md | 2 +-
content/en/docs/setup/best-practices/certificates.md | 2 +-
.../tasks/administer-cluster/kubeadm/kubeadm-certs.md | 2 +-
.../tasks/administer-cluster/securing-a-cluster.md | 11 ++++-------
content/en/docs/tasks/tls/certificate-rotation.md | 2 +-
12 files changed, 19 insertions(+), 22 deletions(-)
diff --git a/content/en/docs/concepts/architecture/control-plane-node-communication.md b/content/en/docs/concepts/architecture/control-plane-node-communication.md
index a4814aab4b..e2004f146c 100644
--- a/content/en/docs/concepts/architecture/control-plane-node-communication.md
+++ b/content/en/docs/concepts/architecture/control-plane-node-communication.md
@@ -21,7 +21,7 @@ This document catalogs the communication paths between the control plane (apiser
Kubernetes has a "hub-and-spoke" API pattern. All API usage from nodes (or the pods they run) terminates at the apiserver. None of the other control plane components are designed to expose remote services. The apiserver is configured to listen for remote connections on a secure HTTPS port (typically 443) with one or more forms of client [authentication](/docs/reference/access-authn-authz/authentication/) enabled.
One or more forms of [authorization](/docs/reference/access-authn-authz/authorization/) should be enabled, especially if [anonymous requests](/docs/reference/access-authn-authz/authentication/#anonymous-requests) or [service account tokens](/docs/reference/access-authn-authz/authentication/#service-account-tokens) are allowed.
-Nodes should be provisioned with the public root certificate for the cluster such that they can connect securely to the apiserver along with valid client credentials. A good approach is that the client credentials provided to the kubelet are in the form of a client certificate. See [kubelet TLS bootstrapping](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/) for automated provisioning of kubelet client certificates.
+Nodes should be provisioned with the public root certificate for the cluster such that they can connect securely to the apiserver along with valid client credentials. A good approach is that the client credentials provided to the kubelet are in the form of a client certificate. See [kubelet TLS bootstrapping](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/) for automated provisioning of kubelet client certificates.
Pods that wish to connect to the apiserver can do so securely by leveraging a service account so that Kubernetes will automatically inject the public root certificate and a valid bearer token into the pod when it is instantiated.
The `kubernetes` service (in `default` namespace) is configured with a virtual IP address that is redirected (via kube-proxy) to the HTTPS endpoint on the apiserver.
@@ -49,7 +49,7 @@ To verify this connection, use the `--kubelet-certificate-authority` flag to pro
If that is not possible, use [SSH tunneling](#ssh-tunnels) between the apiserver and kubelet if required to avoid connecting over an
untrusted or public network.
-Finally, [Kubelet authentication and/or authorization](/docs/reference/command-line-tools-reference/kubelet-authentication-authorization/) should be enabled to secure the kubelet API.
+Finally, [Kubelet authentication and/or authorization](/docs/reference/access-authn-authz/kubelet-authn-authz/) should be enabled to secure the kubelet API.
### apiserver to nodes, pods, and services
diff --git a/content/en/docs/concepts/cluster-administration/_index.md b/content/en/docs/concepts/cluster-administration/_index.md
index 7d5aec5078..d8bb3e361b 100644
--- a/content/en/docs/concepts/cluster-administration/_index.md
+++ b/content/en/docs/concepts/cluster-administration/_index.md
@@ -63,8 +63,8 @@ Before choosing a guide, here are some considerations:
### Securing the kubelet
* [Control Plane-Node communication](/docs/concepts/architecture/control-plane-node-communication/)
- * [TLS bootstrapping](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/)
- * [Kubelet authentication/authorization](/docs/reference/command-line-tools-reference/kubelet-authentication-authorization/)
+ * [TLS bootstrapping](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/)
+ * [Kubelet authentication/authorization](/docs/reference/acess-authn-authz/kubelet-authn-authz/)
## Optional Cluster Services
diff --git a/content/en/docs/reference/access-authn-authz/bootstrap-tokens.md b/content/en/docs/reference/access-authn-authz/bootstrap-tokens.md
index 7e743be63d..f9a6481798 100644
--- a/content/en/docs/reference/access-authn-authz/bootstrap-tokens.md
+++ b/content/en/docs/reference/access-authn-authz/bootstrap-tokens.md
@@ -15,7 +15,7 @@ creating new clusters or joining new nodes to an existing cluster. It was built
to support [kubeadm](/docs/reference/setup-tools/kubeadm/), but can be used in other contexts
for users that wish to start clusters without `kubeadm`. It is also built to
work, via RBAC policy, with the
-[Kubelet TLS Bootstrapping](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/) system.
+[Kubelet TLS Bootstrapping](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/) system.
diff --git a/content/en/docs/reference/access-authn-authz/node.md b/content/en/docs/reference/access-authn-authz/node.md
index 6e7c538eb0..bc9863219f 100644
--- a/content/en/docs/reference/access-authn-authz/node.md
+++ b/content/en/docs/reference/access-authn-authz/node.md
@@ -43,7 +43,7 @@ have the minimal set of permissions required to operate correctly.
In order to be authorized by the Node authorizer, kubelets must use a credential that identifies them as
being in the `system:nodes` group, with a username of `system:node:`.
This group and user name format match the identity created for each kubelet as part of
-[kubelet TLS bootstrapping](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/).
+[kubelet TLS bootstrapping](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/).
The value of `` **must** match precisely the name of the node as registered by the kubelet. By default, this is the host name as provided by `hostname`, or overridden via the [kubelet option](/docs/reference/command-line-tools-reference/kubelet/) `--hostname-override`. However, when using the `--cloud-provider` kubelet option, the specific hostname may be determined by the cloud provider, ignoring the local `hostname` and the `--hostname-override` option.
For specifics about how the kubelet determines the hostname, see the [kubelet options reference](/docs/reference/command-line-tools-reference/kubelet/).
diff --git a/content/en/docs/reference/access-authn-authz/rbac.md b/content/en/docs/reference/access-authn-authz/rbac.md
index 57a074a29a..d085251e43 100644
--- a/content/en/docs/reference/access-authn-authz/rbac.md
+++ b/content/en/docs/reference/access-authn-authz/rbac.md
@@ -798,7 +798,7 @@ This is commonly used by add-on API servers for unified authentication and autho
diff --git a/content/en/docs/reference/command-line-tools-reference/feature-gates.md b/content/en/docs/reference/command-line-tools-reference/feature-gates.md
index f6dbbb97a8..63e1f8fee1 100644
--- a/content/en/docs/reference/command-line-tools-reference/feature-gates.md
+++ b/content/en/docs/reference/command-line-tools-reference/feature-gates.md
@@ -1028,10 +1028,10 @@ Each feature gate is designed for enabling/disabling a specific feature:
[Bound Service Account Tokens](https://github.com/kubernetes/enhancements/blob/master/keps/sig-auth/1205-bound-service-account-tokens/README.md)
for more details.
- `RotateKubeletClientCertificate`: Enable the rotation of the client TLS certificate on the kubelet.
- See [kubelet configuration](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/#kubelet-configuration)
+ See [kubelet configuration](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/#kubelet-configuration)
for more details.
- `RotateKubeletServerCertificate`: Enable the rotation of the server TLS certificate on the kubelet.
- See [kubelet configuration](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/#kubelet-configuration)
+ See [kubelet configuration](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/#kubelet-configuration)
for more details.
- `RunAsGroup`: Enable control over the primary group ID set on the init
processes of containers.
diff --git a/content/en/docs/reference/setup-tools/kubeadm/implementation-details.md b/content/en/docs/reference/setup-tools/kubeadm/implementation-details.md
index 137a9bcd04..bd35ce5002 100644
--- a/content/en/docs/reference/setup-tools/kubeadm/implementation-details.md
+++ b/content/en/docs/reference/setup-tools/kubeadm/implementation-details.md
@@ -224,7 +224,7 @@ Other API server flags that are set unconditionally are:
- `--insecure-port=0` to avoid insecure connections to the api server
- `--enable-bootstrap-token-auth=true` to enable the `BootstrapTokenAuthenticator` authentication module.
- See [TLS Bootstrapping](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/) for more details
+ See [TLS Bootstrapping](/docs/reference/access-authn-authn/kubelet-tls-bootstrapping/) for more details
- `--allow-privileged` to `true` (required e.g. by kube proxy)
- `--requestheader-client-ca-file` to `front-proxy-ca.crt`
- `--enable-admission-plugins` to:
@@ -271,7 +271,7 @@ The static Pod manifest for the controller manager is affected by following para
Other flags that are set unconditionally are:
- `--controllers` enabling all the default controllers plus `BootstrapSigner` and `TokenCleaner` controllers for TLS bootstrap.
- See [TLS Bootstrapping](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/) for more details
+ See [TLS Bootstrapping](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/) for more details
- `--use-service-account-credentials` to `true`
- Flags for using certificates generated in previous steps:
- `--root-ca-file` to `ca.crt`
diff --git a/content/en/docs/reference/setup-tools/kubeadm/kubeadm-init.md b/content/en/docs/reference/setup-tools/kubeadm/kubeadm-init.md
index a8d514ad14..90de85660b 100644
--- a/content/en/docs/reference/setup-tools/kubeadm/kubeadm-init.md
+++ b/content/en/docs/reference/setup-tools/kubeadm/kubeadm-init.md
@@ -52,7 +52,7 @@ following steps:
1. Makes all the necessary configurations for allowing node joining with the
[Bootstrap Tokens](/docs/reference/access-authn-authz/bootstrap-tokens/) and
- [TLS Bootstrap](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/)
+ [TLS Bootstrap](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/)
mechanism:
- Write a ConfigMap for making available all the information required
diff --git a/content/en/docs/setup/best-practices/certificates.md b/content/en/docs/setup/best-practices/certificates.md
index 6d6d576c39..23e4ac8df7 100644
--- a/content/en/docs/setup/best-practices/certificates.md
+++ b/content/en/docs/setup/best-practices/certificates.md
@@ -22,7 +22,7 @@ This page explains the certificates that your cluster requires.
Kubernetes requires PKI for the following operations:
* Client certificates for the kubelet to authenticate to the API server
-* Kubelet [server certificates](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/#client-and-serving-certificates)
+* Kubelet [server certificates](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/#client-and-serving-certificates)
for the API server to talk to the kubelets
* Server certificate for the API server endpoint
* Client certificates for administrators of the cluster to authenticate to the API server
diff --git a/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-certs.md b/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-certs.md
index 696a69ba82..f846f3c32d 100644
--- a/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-certs.md
+++ b/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-certs.md
@@ -276,7 +276,7 @@ By default, these serving certificate will expire after one year. Kubeadm sets t
`KubeletConfiguration` field `rotateCertificates` to `true`, which means that close
to expiration a new set of CSRs for the serving certificates will be created and must
be approved to complete the rotation. To understand more see
-[Certificate Rotation](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/#certificate-rotation).
+[Certificate Rotation](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/#certificate-rotation).
If you are looking for a solution for automatic approval of these CSRs it is recommended
that you contact your cloud provider and ask if they have a CSR signer that verifies
diff --git a/content/en/docs/tasks/administer-cluster/securing-a-cluster.md b/content/en/docs/tasks/administer-cluster/securing-a-cluster.md
index cc463a86c6..5e0202ac0d 100644
--- a/content/en/docs/tasks/administer-cluster/securing-a-cluster.md
+++ b/content/en/docs/tasks/administer-cluster/securing-a-cluster.md
@@ -13,15 +13,10 @@ content_type: task
This document covers topics related to protecting a cluster from accidental or malicious access
and provides recommendations on overall security.
-
-
## {{% heading "prerequisites" %}}
-
* {{< include "task-tutorial-prereqs.md" >}} {{< version-check >}}
-
-
## Controlling access to the Kubernetes API
@@ -77,11 +72,13 @@ Consult the [authorization reference section](/docs/reference/access-authn-authz
## Controlling access to the Kubelet
-Kubelets expose HTTPS endpoints which grant powerful control over the node and containers. By default Kubelets allow unauthenticated access to this API.
+Kubelets expose HTTPS endpoints which grant powerful control over the node and containers.
+By default Kubelets allow unauthenticated access to this API.
Production clusters should enable Kubelet authentication and authorization.
-Consult the [Kubelet authentication/authorization reference](/docs/reference/command-line-tools-reference/kubelet-authentication-authorization) for more information.
+Consult the [Kubelet authentication/authorization reference](/docs/reference/access-authn-authz/kubelet-authn-authz/)
+for more information.
## Controlling the capabilities of a workload or user at runtime
diff --git a/content/en/docs/tasks/tls/certificate-rotation.md b/content/en/docs/tasks/tls/certificate-rotation.md
index 2db0c1255d..8d1992845c 100644
--- a/content/en/docs/tasks/tls/certificate-rotation.md
+++ b/content/en/docs/tasks/tls/certificate-rotation.md
@@ -28,7 +28,7 @@ default, these certificates are issued with one year expiration so that they do
not need to be renewed too frequently.
Kubernetes contains [kubelet certificate
-rotation](/docs/reference/command-line-tools-reference/kubelet-tls-bootstrapping/),
+rotation](/docs/reference/access-authn-authz/kubelet-tls-bootstrapping/),
that will automatically generate a new key and request a new certificate from
the Kubernetes API as the current certificate approaches expiration. Once the
new certificate is available, it will be used for authenticating connections to
From 3bc5af67f9243cf6f982a241c9aca6d1088f481e Mon Sep 17 00:00:00 2001
From: Mitesh Jain <47820816+miteshskj@users.noreply.github.com>
Date: Sat, 23 Apr 2022 19:29:16 +0530
Subject: [PATCH 020/331] Remove repeated, confusing information about
cgroupfs.
---
.../administer-cluster/kubeadm/configure-cgroup-driver.md | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/content/en/docs/tasks/administer-cluster/kubeadm/configure-cgroup-driver.md b/content/en/docs/tasks/administer-cluster/kubeadm/configure-cgroup-driver.md
index 31a9ff0e33..cacfcc281c 100644
--- a/content/en/docs/tasks/administer-cluster/kubeadm/configure-cgroup-driver.md
+++ b/content/en/docs/tasks/administer-cluster/kubeadm/configure-cgroup-driver.md
@@ -68,9 +68,7 @@ and passing it to the local node kubelet.
## Using the `cgroupfs` driver
-As this guide explains using the `cgroupfs` driver with kubeadm is not recommended.
-
-To continue using `cgroupfs` and to prevent `kubeadm upgrade` from modifying the
+To use `cgroupfs` and to prevent `kubeadm upgrade` from modifying the
`KubeletConfiguration` cgroup driver on existing setups, you must be explicit
about its value. This applies to a case where you do not wish future versions
of kubeadm to apply the `systemd` driver by default.
From c3566e471d149118a94a29fbf422a358c0b64025 Mon Sep 17 00:00:00 2001
From: "Mr. Erlison"
Date: Sat, 23 Apr 2022 12:34:14 -0300
Subject: [PATCH 021/331] Add
pt-br/docs/reference/glossary/application-developer.md
---
.../reference/glossary/application-developer.md | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
create mode 100644 content/pt-br/docs/reference/glossary/application-developer.md
diff --git a/content/pt-br/docs/reference/glossary/application-developer.md b/content/pt-br/docs/reference/glossary/application-developer.md
new file mode 100644
index 0000000000..037a9413ad
--- /dev/null
+++ b/content/pt-br/docs/reference/glossary/application-developer.md
@@ -0,0 +1,17 @@
+---
+title: Desenvolvedor de Aplicativos
+id: application-developer
+date: 2018-04-12
+full_link:
+short_description: >
+ Uma pessoa que escreve um aplicativo que é executado em um cluster Kubernetes.
+
+aka:
+tags:
+- user-type
+---
+ Uma pessoa que escreve um aplicativo que é executado em um cluster Kubernetes.
+
+
+
+Um desenvolvedor de aplicativos se concentra em uma parte da aplicação. O seu foco pode variar significativamente em tamanho.
From ebdae18bd1b88a2cbbe114601a45c48cb1a59196 Mon Sep 17 00:00:00 2001
From: "Mr. Erlison"
Date: Sat, 23 Apr 2022 12:39:15 -0300
Subject: [PATCH 022/331] Add pt-br/docs/reference/glossary/data-plane.md
---
content/pt-br/docs/reference/glossary/data-plane.md | 13 +++++++++++++
1 file changed, 13 insertions(+)
create mode 100644 content/pt-br/docs/reference/glossary/data-plane.md
diff --git a/content/pt-br/docs/reference/glossary/data-plane.md b/content/pt-br/docs/reference/glossary/data-plane.md
new file mode 100644
index 0000000000..2e7c9946f9
--- /dev/null
+++ b/content/pt-br/docs/reference/glossary/data-plane.md
@@ -0,0 +1,13 @@
+---
+title: Plano de Dados
+id: data-plane
+date: 2019-05-12
+full_link:
+short_description: >
+ A camada que fornece capacidade, tais como CPU, memória, rede e armazenamento, para que os contêineres possam ser executados e conectados a uma rede.
+
+aka:
+tags:
+- fundamental
+---
+ A camada que fornece capacidade, tais como CPU, memória, rede e armazenamento, para que os contêineres possam ser executados e conectados a uma rede.
From 694b4db53d7b585d0617ef6777c85b8d499d86ff Mon Sep 17 00:00:00 2001
From: Alastair Firth
Date: Mon, 25 Apr 2022 11:35:11 +0200
Subject: [PATCH 023/331] Update resource-quotas.md
This line is about 6 years old and has been implemented for some time ;)
https://github.com/kubernetes/website/blame/30e536f6100b4c6a0cebe8b0bab7ebb68fee5cf1~1/docs/admin/resourcequota/index.md#L19
https://kubernetes.slack.com/archives/C8WRR2BB9/p1635968976005100
---
content/en/docs/concepts/policy/resource-quotas.md | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/content/en/docs/concepts/policy/resource-quotas.md b/content/en/docs/concepts/policy/resource-quotas.md
index d31efd09bc..9e2e904f3d 100644
--- a/content/en/docs/concepts/policy/resource-quotas.md
+++ b/content/en/docs/concepts/policy/resource-quotas.md
@@ -22,8 +22,7 @@ be consumed by resources in that namespace.
Resource quotas work like this:
-- Different teams work in different namespaces. Currently this is voluntary, but
- support for making this mandatory via ACLs is planned.
+- Different teams work in different namespaces. This can be enforced with [RBAC](/docs/reference/access-authn-authz/rbac/).
- The administrator creates one ResourceQuota for each namespace.
From c00146a3a67c216524998a7fa3c2761eba28ab86 Mon Sep 17 00:00:00 2001
From: Joel Gerber
Date: Mon, 25 Apr 2022 07:41:33 -0400
Subject: [PATCH 024/331] Update
content/en/docs/reference/using-api/api-concepts.md
Co-authored-by: divya-mohan0209
---
content/en/docs/reference/using-api/api-concepts.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/en/docs/reference/using-api/api-concepts.md b/content/en/docs/reference/using-api/api-concepts.md
index a7a8f1d059..f31bfaff40 100644
--- a/content/en/docs/reference/using-api/api-concepts.md
+++ b/content/en/docs/reference/using-api/api-concepts.md
@@ -15,7 +15,7 @@ primary resources via the standard HTTP verbs (POST, PUT, PATCH, DELETE,
GET).
For some resources, the API includes additional subresources that allow
-fine grained authorization (such as separate viewing details for a Pod from
+fine grained authorization (such as separate views for Pod details and
retrieving its logs), and can accept and serve those resources in different
representations for convenience or efficiency.
From 47be146d8625f1d8590ac0a1af4d8aef82644179 Mon Sep 17 00:00:00 2001
From: Joel Gerber
Date: Mon, 25 Apr 2022 07:41:46 -0400
Subject: [PATCH 025/331] Update
content/en/docs/reference/using-api/api-concepts.md
Co-authored-by: divya-mohan0209
---
content/en/docs/reference/using-api/api-concepts.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/en/docs/reference/using-api/api-concepts.md b/content/en/docs/reference/using-api/api-concepts.md
index f31bfaff40..1a722acffd 100644
--- a/content/en/docs/reference/using-api/api-concepts.md
+++ b/content/en/docs/reference/using-api/api-concepts.md
@@ -16,7 +16,7 @@ GET).
For some resources, the API includes additional subresources that allow
fine grained authorization (such as separate views for Pod details and
-retrieving its logs), and can accept and serve those resources in different
+log retrievals), and can accept and serve those resources in different
representations for convenience or efficiency.
Kubernetes supports efficient change notifications on resources via *watches*.
From c83e9500d240e603b5afc2b59e395adc3731dcec Mon Sep 17 00:00:00 2001
From: Shabir Mohamed Abdul Samadh
<7249208+Shabirmean@users.noreply.github.com>
Date: Mon, 25 Apr 2022 12:57:47 -0400
Subject: [PATCH 026/331] doc: add note about endpoint.name==service.name
For Services without selectors, there is no mention of the requirement that the name of the associated Endpoint object must be the same as the Service name. Thus, I have added that note.
---
content/en/docs/concepts/services-networking/service.md | 2 ++
1 file changed, 2 insertions(+)
diff --git a/content/en/docs/concepts/services-networking/service.md b/content/en/docs/concepts/services-networking/service.md
index fa201c0e1b..7f89b14d0d 100644
--- a/content/en/docs/concepts/services-networking/service.md
+++ b/content/en/docs/concepts/services-networking/service.md
@@ -203,6 +203,8 @@ subsets:
The name of the Endpoints object must be a valid
[DNS subdomain name](/docs/concepts/overview/working-with-objects/names#dns-subdomain-names).
+{{< note >}} The name of the Endpoint must be the same as the name of the Service. {{< /note >}}
+
{{< note >}}
The endpoint IPs _must not_ be: loopback (127.0.0.0/8 for IPv4, ::1/128 for IPv6), or
link-local (169.254.0.0/16 and 224.0.0.0/24 for IPv4, fe80::/64 for IPv6).
From 7454622a18ae7d94380d62fc46cd41f6adff410e Mon Sep 17 00:00:00 2001
From: Shabir Mohamed Abdul Samadh
<7249208+Shabirmean@users.noreply.github.com>
Date: Tue, 26 Apr 2022 07:02:40 -0400
Subject: [PATCH 027/331] doc: adopt suggestion
Co-authored-by: Tim Bannister
---
content/en/docs/concepts/services-networking/service.md | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/content/en/docs/concepts/services-networking/service.md b/content/en/docs/concepts/services-networking/service.md
index 7f89b14d0d..c04e7d6398 100644
--- a/content/en/docs/concepts/services-networking/service.md
+++ b/content/en/docs/concepts/services-networking/service.md
@@ -203,7 +203,9 @@ subsets:
The name of the Endpoints object must be a valid
[DNS subdomain name](/docs/concepts/overview/working-with-objects/names#dns-subdomain-names).
-{{< note >}} The name of the Endpoint must be the same as the name of the Service. {{< /note >}}
+When you create an [Endpoints](docs/reference/kubernetes-api/service-resources/endpoints-v1/)
+object for a Service, you set the name of the new Endpoints to be the same as the
+name of the Service.
{{< note >}}
The endpoint IPs _must not_ be: loopback (127.0.0.0/8 for IPv4, ::1/128 for IPv6), or
From f2ef9858a38eb06e58ec55862b37215d84cb46c2 Mon Sep 17 00:00:00 2001
From: Shabir Mohamed Abdul Samadh
<7249208+Shabirmean@users.noreply.github.com>
Date: Tue, 26 Apr 2022 07:04:44 -0400
Subject: [PATCH 028/331] doc: add comment about the name match in the example
---
content/en/docs/concepts/services-networking/service.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/content/en/docs/concepts/services-networking/service.md b/content/en/docs/concepts/services-networking/service.md
index c04e7d6398..571d5f2a0a 100644
--- a/content/en/docs/concepts/services-networking/service.md
+++ b/content/en/docs/concepts/services-networking/service.md
@@ -192,6 +192,7 @@ where it's running, by adding an Endpoints object manually:
apiVersion: v1
kind: Endpoints
metadata:
+ # the name here should match the name of the Service
name: my-service
subsets:
- addresses:
From 7359d60de8ebea02c8735e1f357f8b7990d9c8c5 Mon Sep 17 00:00:00 2001
From: Qiming Teng
Date: Wed, 27 Apr 2022 10:20:18 +0800
Subject: [PATCH 029/331] Tweak indentation on portforward page
This PR fixes the indentation nits in the
`port-forward-access-application-cluster` page.
We are not supposed to indent lines by 4 spaces because such
indentations may mislead the markdown parser to render them as code
snippets.
---
...port-forward-access-application-cluster.md | 218 ++++++++----------
1 file changed, 102 insertions(+), 116 deletions(-)
diff --git a/content/en/docs/tasks/access-application-cluster/port-forward-access-application-cluster.md b/content/en/docs/tasks/access-application-cluster/port-forward-access-application-cluster.md
index ba8f7b1244..3b2648f943 100644
--- a/content/en/docs/tasks/access-application-cluster/port-forward-access-application-cluster.md
+++ b/content/en/docs/tasks/access-application-cluster/port-forward-access-application-cluster.md
@@ -11,180 +11,169 @@ This page shows how to use `kubectl port-forward` to connect to a MongoDB
server running in a Kubernetes cluster. This type of connection can be useful
for database debugging.
-
-
-
## {{% heading "prerequisites" %}}
-
* {{< include "task-tutorial-prereqs.md" >}} {{< version-check >}}
-
* Install [MongoDB Shell](https://www.mongodb.com/try/download/shell).
-
-
-
## Creating MongoDB deployment and service
1. Create a Deployment that runs MongoDB:
- ```shell
- kubectl apply -f https://k8s.io/examples/application/mongodb/mongo-deployment.yaml
- ```
+ ```shell
+ kubectl apply -f https://k8s.io/examples/application/mongodb/mongo-deployment.yaml
+ ```
- The output of a successful command verifies that the deployment was created:
+ The output of a successful command verifies that the deployment was created:
- ```
- deployment.apps/mongo created
- ```
+ ```
+ deployment.apps/mongo created
+ ```
- View the pod status to check that it is ready:
+ View the pod status to check that it is ready:
- ```shell
- kubectl get pods
- ```
+ ```shell
+ kubectl get pods
+ ```
- The output displays the pod created:
+ The output displays the pod created:
- ```
- NAME READY STATUS RESTARTS AGE
- mongo-75f59d57f4-4nd6q 1/1 Running 0 2m4s
- ```
+ ```
+ NAME READY STATUS RESTARTS AGE
+ mongo-75f59d57f4-4nd6q 1/1 Running 0 2m4s
+ ```
- View the Deployment's status:
+ View the Deployment's status:
- ```shell
- kubectl get deployment
- ```
+ ```shell
+ kubectl get deployment
+ ```
- The output displays that the Deployment was created:
+ The output displays that the Deployment was created:
- ```
- NAME READY UP-TO-DATE AVAILABLE AGE
- mongo 1/1 1 1 2m21s
- ```
+ ```
+ NAME READY UP-TO-DATE AVAILABLE AGE
+ mongo 1/1 1 1 2m21s
+ ```
- The Deployment automatically manages a ReplicaSet.
- View the ReplicaSet status using:
+ The Deployment automatically manages a ReplicaSet.
+ View the ReplicaSet status using:
- ```shell
- kubectl get replicaset
- ```
+ ```shell
+ kubectl get replicaset
+ ```
- The output displays that the ReplicaSet was created:
-
- ```
- NAME DESIRED CURRENT READY AGE
- mongo-75f59d57f4 1 1 1 3m12s
- ```
+ The output displays that the ReplicaSet was created:
+ ```
+ NAME DESIRED CURRENT READY AGE
+ mongo-75f59d57f4 1 1 1 3m12s
+ ```
2. Create a Service to expose MongoDB on the network:
- ```shell
- kubectl apply -f https://k8s.io/examples/application/mongodb/mongo-service.yaml
- ```
+ ```shell
+ kubectl apply -f https://k8s.io/examples/application/mongodb/mongo-service.yaml
+ ```
- The output of a successful command verifies that the Service was created:
+ The output of a successful command verifies that the Service was created:
- ```
- service/mongo created
- ```
+ ```
+ service/mongo created
+ ```
- Check the Service created:
+ Check the Service created:
- ```shell
- kubectl get service mongo
- ```
+ ```shell
+ kubectl get service mongo
+ ```
- The output displays the service created:
+ The output displays the service created:
- ```
- NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
- mongo ClusterIP 10.96.41.183 27017/TCP 11s
- ```
+ ```
+ NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
+ mongo ClusterIP 10.96.41.183 27017/TCP 11s
+ ```
3. Verify that the MongoDB server is running in the Pod, and listening on port 27017:
- ```shell
- # Change mongo-75f59d57f4-4nd6q to the name of the Pod
- kubectl get pod mongo-75f59d57f4-4nd6q --template='{{(index (index .spec.containers 0).ports 0).containerPort}}{{"\n"}}'
- ```
+ ```shell
+ # Change mongo-75f59d57f4-4nd6q to the name of the Pod
+ kubectl get pod mongo-75f59d57f4-4nd6q --template='{{(index (index .spec.containers 0).ports 0).containerPort}}{{"\n"}}'
+ ```
- The output displays the port for MongoDB in that Pod:
+ The output displays the port for MongoDB in that Pod:
- ```
- 27017
- ```
+ ```
+ 27017
+ ```
- (this is the TCP port allocated to MongoDB on the internet).
+ 27017 is the TCP port allocated to MongoDB on the internet.
## Forward a local port to a port on the Pod
-1. `kubectl port-forward` allows using resource name, such as a pod name, to select a matching pod to port forward to.
+1. `kubectl port-forward` allows using resource name, such as a pod name, to select a matching pod to port forward to.
- ```shell
- # Change mongo-75f59d57f4-4nd6q to the name of the Pod
- kubectl port-forward mongo-75f59d57f4-4nd6q 28015:27017
- ```
+ ```shell
+ # Change mongo-75f59d57f4-4nd6q to the name of the Pod
+ kubectl port-forward mongo-75f59d57f4-4nd6q 28015:27017
+ ```
- which is the same as
+ which is the same as
- ```shell
- kubectl port-forward pods/mongo-75f59d57f4-4nd6q 28015:27017
- ```
+ ```shell
+ kubectl port-forward pods/mongo-75f59d57f4-4nd6q 28015:27017
+ ```
- or
+ or
- ```shell
- kubectl port-forward deployment/mongo 28015:27017
- ```
+ ```shell
+ kubectl port-forward deployment/mongo 28015:27017
+ ```
- or
+ or
- ```shell
- kubectl port-forward replicaset/mongo-75f59d57f4 28015:27017
- ```
+ ```shell
+ kubectl port-forward replicaset/mongo-75f59d57f4 28015:27017
+ ```
- or
+ or
- ```shell
- kubectl port-forward service/mongo 28015:27017
- ```
+ ```shell
+ kubectl port-forward service/mongo 28015:27017
+ ```
- Any of the above commands works. The output is similar to this:
+ Any of the above commands works. The output is similar to this:
- ```
- Forwarding from 127.0.0.1:28015 -> 27017
- Forwarding from [::1]:28015 -> 27017
- ```
+ ```
+ Forwarding from 127.0.0.1:28015 -> 27017
+ Forwarding from [::1]:28015 -> 27017
+ ```
-{{< note >}}
+ {{< note >}}
+ `kubectl port-forward` does not return. To continue with the exercises, you will need to open another terminal.
+ {{< /note >}}
-`kubectl port-forward` does not return. To continue with the exercises, you will need to open another terminal.
+2. Start the MongoDB command line interface:
-{{< /note >}}
+ ```shell
+ mongosh --port 28015
+ ```
-2. Start the MongoDB command line interface:
+3. At the MongoDB command line prompt, enter the `ping` command:
- ```shell
- mongosh --port 28015
- ```
+ ```
+ db.runCommand( { ping: 1 } )
+ ```
-3. At the MongoDB command line prompt, enter the `ping` command:
+ A successful ping request returns:
- ```
- db.runCommand( { ping: 1 } )
- ```
-
- A successful ping request returns:
-
- ```
- { ok: 1 }
- ```
+ ```
+ { ok: 1 }
+ ```
### Optionally let _kubectl_ choose the local port {#let-kubectl-choose-local-port}
@@ -204,7 +193,6 @@ Forwarding from 127.0.0.1:63753 -> 27017
Forwarding from [::1]:63753 -> 27017
```
-
## Discussion
@@ -219,9 +207,7 @@ The support for UDP protocol is tracked in
[issue 47862](https://github.com/kubernetes/kubernetes/issues/47862).
{{< /note >}}
-
-
-
## {{% heading "whatsnext" %}}
Learn more about [kubectl port-forward](/docs/reference/generated/kubectl/kubectl-commands/#port-forward).
+
From dc7bed20cf9b35d04ce7772ddfbbf845f8eddebb Mon Sep 17 00:00:00 2001
From: Qiming Teng
Date: Wed, 27 Apr 2022 16:06:06 +0800
Subject: [PATCH 030/331] Tweak kubeadm-upgrade page for indentation nits
The indentation on the page is "messy". We don't encourage implicit code blocks (4-space indentations). The nesting of contents are not properly expressed either.
---
.../kubeadm/kubeadm-upgrade.md | 275 ++++++++++--------
1 file changed, 146 insertions(+), 129 deletions(-)
diff --git a/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade.md b/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade.md
index 36e5a1a00c..f6706ea68a 100644
--- a/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade.md
+++ b/content/en/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade.md
@@ -79,83 +79,87 @@ Pick a control plane node that you wish to upgrade first. It must have the `/etc
**For the first control plane node**
-- Upgrade kubeadm:
+- Upgrade kubeadm:
-{{< tabs name="k8s_install_kubeadm_first_cp" >}}
-{{% tab name="Ubuntu, Debian or HypriotOS" %}}
- # replace x in {{< skew currentVersion >}}.x-00 with the latest patch version
- apt-mark unhold kubeadm && \
- apt-get update && apt-get install -y kubeadm={{< skew currentVersion >}}.x-00 && \
- apt-mark hold kubeadm
-{{% /tab %}}
-{{% tab name="CentOS, RHEL or Fedora" %}}
- # replace x in {{< skew currentVersion >}}.x-0 with the latest patch version
- yum install -y kubeadm-{{< skew currentVersion >}}.x-0 --disableexcludes=kubernetes
-{{% /tab %}}
-{{< /tabs >}}
-
+ {{< tabs name="k8s_install_kubeadm_first_cp" >}}
+ {{% tab name="Ubuntu, Debian or HypriotOS" %}}
+ ```shell
+ # replace x in {{< skew currentVersion >}}.x-00 with the latest patch version
+ apt-mark unhold kubeadm && \
+ apt-get update && apt-get install -y kubeadm={{< skew currentVersion >}}.x-00 && \
+ apt-mark hold kubeadm
+ ```
+ {{% /tab %}}
+ {{% tab name="CentOS, RHEL or Fedora" %}}
+ ```shell
+ # replace x in {{< skew currentVersion >}}.x-0 with the latest patch version
+ yum install -y kubeadm-{{< skew currentVersion >}}.x-0 --disableexcludes=kubernetes
+ ```
+ {{% /tab %}}
+ {{< /tabs >}}
+
-- Verify that the download works and has the expected version:
+- Verify that the download works and has the expected version:
- ```shell
- kubeadm version
- ```
+ ```shell
+ kubeadm version
+ ```
-- Verify the upgrade plan:
+- Verify the upgrade plan:
- ```shell
- kubeadm upgrade plan
- ```
+ ```shell
+ kubeadm upgrade plan
+ ```
- This command checks that your cluster can be upgraded, and fetches the versions you can upgrade to.
- It also shows a table with the component config version states.
+ This command checks that your cluster can be upgraded, and fetches the versions you can upgrade to.
+ It also shows a table with the component config version states.
-{{< note >}}
-`kubeadm upgrade` also automatically renews the certificates that it manages on this node.
-To opt-out of certificate renewal the flag `--certificate-renewal=false` can be used.
-For more information see the [certificate management guide](/docs/tasks/administer-cluster/kubeadm/kubeadm-certs).
-{{ note >}}
+ {{< note >}}
+ `kubeadm upgrade` also automatically renews the certificates that it manages on this node.
+ To opt-out of certificate renewal the flag `--certificate-renewal=false` can be used.
+ For more information see the [certificate management guide](/docs/tasks/administer-cluster/kubeadm/kubeadm-certs).
+ {{ note >}}
+
+ {{< note >}}
+ If `kubeadm upgrade plan` shows any component configs that require manual upgrade, users must provide
+ a config file with replacement configs to `kubeadm upgrade apply` via the `--config` command line flag.
+ Failing to do so will cause `kubeadm upgrade apply` to exit with an error and not perform an upgrade.
+ {{ note >}}
-{{< note >}}
-If `kubeadm upgrade plan` shows any component configs that require manual upgrade, users must provide
-a config file with replacement configs to `kubeadm upgrade apply` via the `--config` command line flag.
-Failing to do so will cause `kubeadm upgrade apply` to exit with an error and not perform an upgrade.
-{{ note >}}
+- Choose a version to upgrade to, and run the appropriate command. For example:
-- Choose a version to upgrade to, and run the appropriate command. For example:
+ ```shell
+ # replace x with the patch version you picked for this upgrade
+ sudo kubeadm upgrade apply v{{< skew currentVersion >}}.x
+ ```
- ```shell
- # replace x with the patch version you picked for this upgrade
- sudo kubeadm upgrade apply v{{< skew currentVersion >}}.x
- ```
+ Once the command finishes you should see:
- Once the command finishes you should see:
+ ```
+ [upgrade/successful] SUCCESS! Your cluster was upgraded to "v{{< skew currentVersion >}}.x". Enjoy!
- ```
- [upgrade/successful] SUCCESS! Your cluster was upgraded to "v{{< skew currentVersion >}}.x". Enjoy!
+ [upgrade/kubelet] Now that your control plane is upgraded, please proceed with upgrading your kubelets if you haven't already done so.
+ ```
- [upgrade/kubelet] Now that your control plane is upgraded, please proceed with upgrading your kubelets if you haven't already done so.
- ```
+- Manually upgrade your CNI provider plugin.
-- Manually upgrade your CNI provider plugin.
+ Your Container Network Interface (CNI) provider may have its own upgrade instructions to follow.
+ Check the [addons](/docs/concepts/cluster-administration/addons/) page to
+ find your CNI provider and see whether additional upgrade steps are required.
- Your Container Network Interface (CNI) provider may have its own upgrade instructions to follow.
- Check the [addons](/docs/concepts/cluster-administration/addons/) page to
- find your CNI provider and see whether additional upgrade steps are required.
-
- This step is not required on additional control plane nodes if the CNI provider runs as a DaemonSet.
+ This step is not required on additional control plane nodes if the CNI provider runs as a DaemonSet.
**For the other control plane nodes**
Same as the first control plane node but use:
-```
+```shell
sudo kubeadm upgrade node
```
instead of:
-```
+```shell
sudo kubeadm upgrade apply
```
@@ -163,46 +167,50 @@ Also calling `kubeadm upgrade plan` and upgrading the CNI provider plugin is no
### Drain the node
-- Prepare the node for maintenance by marking it unschedulable and evicting the workloads:
+- Prepare the node for maintenance by marking it unschedulable and evicting the workloads:
- ```shell
- # replace with the name of your node you are draining
- kubectl drain --ignore-daemonsets
- ```
+ ```shell
+ # replace with the name of your node you are draining
+ kubectl drain --ignore-daemonsets
+ ```
### Upgrade kubelet and kubectl
-- Upgrade the kubelet and kubectl:
+- Upgrade the kubelet and kubectl:
-{{< tabs name="k8s_install_kubelet" >}}
-{{% tab name="Ubuntu, Debian or HypriotOS" %}}
- # replace x in {{< skew currentVersion >}}.x-00 with the latest patch version
- apt-mark unhold kubelet kubectl && \
- apt-get update && apt-get install -y kubelet={{< skew currentVersion >}}.x-00 kubectl={{< skew currentVersion >}}.x-00 && \
- apt-mark hold kubelet kubectl
-{{% /tab %}}
-{{% tab name="CentOS, RHEL or Fedora" %}}
- # replace x in {{< skew currentVersion >}}.x-0 with the latest patch version
- yum install -y kubelet-{{< skew currentVersion >}}.x-0 kubectl-{{< skew currentVersion >}}.x-0 --disableexcludes=kubernetes
-{{% /tab %}}
-{{< /tabs >}}
-
+ {{< tabs name="k8s_install_kubelet" >}}
+ {{% tab name="Ubuntu, Debian or HypriotOS" %}}
+ ```shell
+ # replace x in {{< skew currentVersion >}}.x-00 with the latest patch version
+ apt-mark unhold kubelet kubectl && \
+ apt-get update && apt-get install -y kubelet={{< skew currentVersion >}}.x-00 kubectl={{< skew currentVersion >}}.x-00 && \
+ apt-mark hold kubelet kubectl
+ ```
+ {{% /tab %}}
+ {{% tab name="CentOS, RHEL or Fedora" %}}
+ ```shell
+ # replace x in {{< skew currentVersion >}}.x-0 with the latest patch version
+ yum install -y kubelet-{{< skew currentVersion >}}.x-0 kubectl-{{< skew currentVersion >}}.x-0 --disableexcludes=kubernetes
+ ```
+ {{% /tab %}}
+ {{< /tabs >}}
+
-- Restart the kubelet:
+- Restart the kubelet:
- ```shell
- sudo systemctl daemon-reload
- sudo systemctl restart kubelet
- ```
+ ```shell
+ sudo systemctl daemon-reload
+ sudo systemctl restart kubelet
+ ```
### Uncordon the node
-- Bring the node back online by marking it schedulable:
+- Bring the node back online by marking it schedulable:
- ```shell
- # replace with the name of your node
- kubectl uncordon
- ```
+ ```shell
+ # replace with the name of your node
+ kubectl uncordon
+ ```
## Upgrade worker nodes
@@ -211,76 +219,83 @@ without compromising the minimum required capacity for running your workloads.
### Upgrade kubeadm
-- Upgrade kubeadm:
+- Upgrade kubeadm:
-{{< tabs name="k8s_install_kubeadm_worker_nodes" >}}
-{{% tab name="Ubuntu, Debian or HypriotOS" %}}
- # replace x in {{< skew currentVersion >}}.x-00 with the latest patch version
- apt-mark unhold kubeadm && \
- apt-get update && apt-get install -y kubeadm={{< skew currentVersion >}}.x-00 && \
- apt-mark hold kubeadm
-{{% /tab %}}
-{{% tab name="CentOS, RHEL or Fedora" %}}
- # replace x in {{< skew currentVersion >}}.x-0 with the latest patch version
- yum install -y kubeadm-{{< skew currentVersion >}}.x-0 --disableexcludes=kubernetes
-{{% /tab %}}
-{{< /tabs >}}
+ {{< tabs name="k8s_install_kubeadm_worker_nodes" >}}
+ {{% tab name="Ubuntu, Debian or HypriotOS" %}}
+ ```shell
+ # replace x in {{< skew currentVersion >}}.x-00 with the latest patch version
+ apt-mark unhold kubeadm && \
+ apt-get update && apt-get install -y kubeadm={{< skew currentVersion >}}.x-00 && \
+ apt-mark hold kubeadm
+ ```
+ {{% /tab %}}
+ {{% tab name="CentOS, RHEL or Fedora" %}}
+ ```shell
+ # replace x in {{< skew currentVersion >}}.x-0 with the latest patch version
+ yum install -y kubeadm-{{< skew currentVersion >}}.x-0 --disableexcludes=kubernetes
+ ```
+ {{% /tab %}}
+ {{< /tabs >}}
### Call "kubeadm upgrade"
-- For worker nodes this upgrades the local kubelet configuration:
+- For worker nodes this upgrades the local kubelet configuration:
- ```shell
- sudo kubeadm upgrade node
- ```
+ ```shell
+ sudo kubeadm upgrade node
+ ```
### Drain the node
-- Prepare the node for maintenance by marking it unschedulable and evicting the workloads:
+- Prepare the node for maintenance by marking it unschedulable and evicting the workloads:
- ```shell
- # replace with the name of your node you are draining
- kubectl drain --ignore-daemonsets
- ```
+ ```shell
+ # replace with the name of your node you are draining
+ kubectl drain --ignore-daemonsets
+ ```
### Upgrade kubelet and kubectl
-- Upgrade the kubelet and kubectl:
+- Upgrade the kubelet and kubectl:
-{{< tabs name="k8s_kubelet_and_kubectl" >}}
-{{% tab name="Ubuntu, Debian or HypriotOS" %}}
- # replace x in {{< skew currentVersion >}}.x-00 with the latest patch version
- apt-mark unhold kubelet kubectl && \
- apt-get update && apt-get install -y kubelet={{< skew currentVersion >}}.x-00 kubectl={{< skew currentVersion >}}.x-00 && \
- apt-mark hold kubelet kubectl
-{{% /tab %}}
-{{% tab name="CentOS, RHEL or Fedora" %}}
- # replace x in {{< skew currentVersion >}}.x-0 with the latest patch version
- yum install -y kubelet-{{< skew currentVersion >}}.x-0 kubectl-{{< skew currentVersion >}}.x-0 --disableexcludes=kubernetes
-{{% /tab %}}
-{{< /tabs >}}
-
+ {{< tabs name="k8s_kubelet_and_kubectl" >}}
+ {{% tab name="Ubuntu, Debian or HypriotOS" %}}
+ ```shell
+ # replace x in {{< skew currentVersion >}}.x-00 with the latest patch version
+ apt-mark unhold kubelet kubectl && \
+ apt-get update && apt-get install -y kubelet={{< skew currentVersion >}}.x-00 kubectl={{< skew currentVersion >}}.x-00 && \
+ apt-mark hold kubelet kubectl
+ {{% /tab %}}
+ {{% tab name="CentOS, RHEL or Fedora" %}}
+ ```shell
+ # replace x in {{< skew currentVersion >}}.x-0 with the latest patch version
+ yum install -y kubelet-{{< skew currentVersion >}}.x-0 kubectl-{{< skew currentVersion >}}.x-0 --disableexcludes=kubernetes
+ ```
+ {{% /tab %}}
+ {{< /tabs >}}
+
-- Restart the kubelet:
+- Restart the kubelet:
- ```shell
- sudo systemctl daemon-reload
- sudo systemctl restart kubelet
- ```
+ ```shell
+ sudo systemctl daemon-reload
+ sudo systemctl restart kubelet
+ ```
### Uncordon the node
-- Bring the node back online by marking it schedulable:
+- Bring the node back online by marking it schedulable:
- ```shell
- # replace with the name of your node
- kubectl uncordon
- ```
+ ```shell
+ # replace with the name of your node
+ kubectl uncordon
+ ```
## Verify the status of the cluster
-After the kubelet is upgraded on all nodes verify that all nodes are available again by running the following command
-from anywhere kubectl can access the cluster:
+After the kubelet is upgraded on all nodes verify that all nodes are available again by running
+the following command from anywhere kubectl can access the cluster:
```shell
kubectl get nodes
@@ -296,6 +311,7 @@ This command is idempotent and eventually makes sure that the actual state is th
To recover from a bad state, you can also run `kubeadm upgrade apply --force` without changing the version that your cluster is running.
During upgrade kubeadm writes the following backup folders under `/etc/kubernetes/tmp`:
+
- `kubeadm-backup-etcd--
@@ -1267,7 +1269,7 @@ Defaults to the hostname of the node if not provided.
string
-
criSocket is used to retrieve container runtime information. This information will
+
criSocket is used to retrieve container runtime information. This information will
be annotated to the Node API object, for later re-use.
@@ -1276,9 +1278,9 @@ be annotated to the Node API object, for later re-use.
taints specifies the taints the Node API object should be registered with.
-If this field is unset, i.e. nil, in the kubeadm init process it will be defaulted to
-'node-role.kubernetes.io/master=""'. If you don't want to taint your control-plane node,
-set this field to an empty list, i.e. taints: [] in the YAML file. This field is
+If this field is unset, i.e. nil, in the kubeadm init process it will be defaulted with
+a control-plane taint for control-plane nodes. If you don't want to taint your control-plane
+node, set this field to an empty list, i.e. taints: [], in the YAML file. This field is
solely used for Node registration.
diff --git a/content/en/docs/reference/config-api/kubeadm-config.v1beta3.md b/content/en/docs/reference/config-api/kubeadm-config.v1beta3.md
index ca7ef7c287..75fc7c1ecf 100644
--- a/content/en/docs/reference/config-api/kubeadm-config.v1beta3.md
+++ b/content/en/docs/reference/config-api/kubeadm-config.v1beta3.md
@@ -152,7 +152,7 @@ configuration types to be used during a kubeadm init run.
criSocket:"/var/run/dockershim.sock"taints:- key:"kubeadmNode"
-value:"master"
+value:"someValue"effect:"NoSchedule"kubeletExtraArgs:v:4
@@ -1160,9 +1160,9 @@ This information will be annotated to the Node API object, for later re-use
tains specifies the taints the Node API object should be registered with.
-If this field is unset, i.e. nil, in the kubeadm init process it will be defaulted to
-taints: ["node-role.kubernetes.io/master:""].
-If you don't want to taint your control-plane node, set this field to an empty slice,
+If this field is unset, i.e. nil, in the kubeadm init process it will be defaulted
+with a control-plane taint for control-plane nodes.
+If you don't want to taint your control-plane node, set this field to an empty list,
i.e. taints: [] in the YAML file. This field is solely used for Node registration.
@@ -218,16 +201,11 @@ Default: 10250
no authentication/authorization.
The port number must be between 1 and 65535, inclusive.
Setting this field to 0 disables the read-only service.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may disrupt components that interact with the Kubelet server.
Default: 0 (disabled)
-->
@@ -241,17 +219,12 @@ if any, concatenated after server cert). If tlsCertFile and
tlsPrivateKeyFile are not provided, a self-signed certificate
and key are generated for the public address and saved to the directory
passed to the Kubelet's --cert-dir flag.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may disrupt components that interact with the Kubelet server.
Default:"quot;
-->
默认值:false
@@ -343,20 +294,12 @@ signing a serving certificate, the Kubelet will request a certificate from
the 'certificates.k8s.io' API. This requires an approver to approve the
certificate signing requests (CSR). The RotateKubeletServerCertificate feature
must be enabled when setting this field.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-disabling it will stop the renewal of Kubelet server certificates, which can
-disrupt components that interact with the Kubelet server in the long term,
-due to certificate expiration.
Default: false
-->
serverTLSBootstrap用来启用服务器证书引导。系统不再使用自签名的服务证书,
kubelet 会调用certificates.k8s.io API 来请求证书。
需要有一个批复人来批准证书签名请求(CSR)。
设置此字段时,RotateKubeletServerCertificate特性必须被启用。
默认值:5
@@ -446,17 +373,11 @@ Default: 5
pulls to burst to this number, while still not exceeding registryPullQPS.
The value must not be a negative number.
Only used if registryPullQPS is greater than 0.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may impact scalability by changing the amount of traffic produced
-by image pulls.
Default: 10
-->
@@ -769,19 +618,12 @@ image garbage collection is always run. The percent is calculated by
dividing this field value by 100, so this field must be between 0 and
100, inclusive. When specified, the value must be greater than
imageGCLowThresholdPercent.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may trigger or delay garbage collection, and may change the image overhead
-on the node.
Default: 85
-->
@@ -795,37 +637,25 @@ image garbage collection is never run. Lowest disk usage to garbage
collect to. The percent is calculated by dividing this field value by 100,
so the field value must be between 0 and 100, inclusive. When specified, the
value must be less than imageGCHighThresholdPercent.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may trigger or delay garbage collection, and may change the image overhead
-on the node.
Default: 80
-->
@@ -854,15 +680,11 @@ Default: ""
all non-kernel processes that are not already in a container. Empty
for no container. Rolling back the flag requires a reboot.
The cgroupRoot must be specified if this field is not empty.
-Dynamic Kubelet Config (deprecated): This field should not be updated without a full node
-reboot. It is safest to keep this value the same as the local config.
Default: "&qout;
-->
@@ -1016,8 +806,6 @@ resources;
of CPU and device resources.
Policies other than "none" require the TopologyManager feature gate to be enabled.
-Dynamic Kubelet Config (deprecated): This field should not be updated without a full node
-reboot. It is safest to keep this value the same as the local config.
Default: "none"
-->
topologyManagerPolicy是要使用的拓扑管理器策略名称。合法值包括:
@@ -1028,8 +816,6 @@ Default: "none"
single-numa-node:kubelet 仅允许在 CPU 和设备资源上对齐到同一 NUMA 节点的 Pod。
@@ -1068,34 +854,25 @@ the minimum percentage of a resource reserved for exclusive use by the
guaranteed QoS tier.
Currently supported resources: "memory"
Requires the QOSReserved feature gate to be enabled.
-Dynamic Kubelet Config (deprecated): This field should not be updated without a full node
-reboot. It is safest to keep this value the same as the local config.
Default: nil
-->
kubeAPIQPS设置与 Kubernetes API 服务器通信时要使用的 QPS(每秒查询数)。
-
当 DynamicKubeletConfig (已弃用,默认为关闭)被启用时,
-如果动态更新了此字段,请考虑这可能因为 kubelet 与 API 服务器之间流量的变化而影响集群扩缩能力。
默认值:5
@@ -1357,16 +1065,10 @@ Default: 5
kubeAPIBurst设置与 Kubernetes API 服务器通信时突发的流量级别。
此字段取值不可以是负数。
-
当 DynamicKubeletConfig (已弃用,默认为关闭)被启用时,
-如果动态更新了此字段,请考虑这可能因为 kubelet 与 API 服务器之间流量的变化而影响集群扩缩能力。
默认值:10
@@ -1379,16 +1081,11 @@ Default: 10
at a time. We recommend ∗not∗ changing the default value on nodes that
run docker daemon with version < 1.9 or an Aufs storage backend.
Issue #10959 has more details.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may impact the performance of image pulls.
Default: true
-->
@@ -1493,10 +1168,6 @@ effectively caps the Pod's terminationGracePeriodSeconds value during soft evict
Note: Due to issue #64530, the behavior has a bug where this value currently just
overrides the grace period during soft eviction, which can increase the grace
period from what is set on the Pod. This bug will be fixed in a future release.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-lowering it decreases the amount of time Pods will have to gracefully clean
-up before being killed during a soft eviction.
Default: 0
-->
evictionMaxPodGracePeriod是指达到软性逐出阈值而引起 Pod 终止时,
@@ -1505,9 +1176,6 @@ Pod 可以获得的terminationGracePeriodSeconds。
注意:由于 Issue #64530 的原因,系统中存在一个缺陷,即此处所设置的值会在软性逐出时覆盖
Pod 的宽限期设置,从而有可能增加 Pod 上原本设置的宽限期限时长。
这个缺陷会在未来版本中修复。
-
当 DynamicKubeletConfig (已弃用,默认为关闭)被启用时,
-如果动态更新了此字段,请考虑缩短此宽限期限值会导致软性逐出期间 Pod
-在被杀死之前用来体面地完成清理工作可用的时间。
默认值:0
@@ -1520,16 +1188,11 @@ Pod 的宽限期设置,从而有可能增加 Pod 上原本设置的宽限期
which describe the minimum amount of a given resource the kubelet will reclaim when
performing a pod eviction while that resource is under pressure.
For example: {"imagefs.available": "2Gi"}.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may change how well eviction can manage resource pressure.
Default: nil
-->
evictionMinimumReclaim是一个映射,定义信号名称与最小回收量数值之间的关系。
最小回收量指的是资源压力较大而执行 Pod 驱逐操作时,kubelet 对给定资源的最小回收量。
例如:{"imagefs.available": "2Gi"}。
@@ -1619,18 +1256,12 @@ kubelet 进入崩溃循环(Crash-Loop)状态。
are present on host.
These rules will serve as utility rules for various components, e.g. kube-proxy.
The rules will be created based on iptablesMasqueradeBit and iptablesDropBit.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-disabling it will prevent the Kubelet from healing locally misconfigured iptables rules.
Default: true
-->
@@ -1643,18 +1274,11 @@ Default: true
Values must be within the range [0, 31]. Must be different from other mark bits.
Warning: Please match the value of the corresponding parameter in kube-proxy.
TODO: clean up IPTablesMasqueradeBit in kube-proxy.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it needs to be coordinated with other components, like kube-proxy, and the update
-will only be effective if MakeIPTablesUtilChains is enabled.
Default: 14
-->
@@ -1803,20 +1395,11 @@ managers are running. Valid values include:
pairs that describe resources reserved for non-kubernetes components.
Currently only cpu and memory are supported.
See http://kubernetes.io/docs/user-guide/compute-resources for more detail.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may not be possible to increase the reserved resources, because this
-requires resizing cgroups. Always look for a NodeAllocatableEnforced event
-after updating this field to ensure that the update was successful.
Default: nil
-->
@@ -1830,21 +1413,12 @@ that describe resources reserved for kubernetes system components.
Currently cpu, memory and local storage for root file system are supported.
See https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
for more details.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-it may not be possible to increase the reserved resources, because this
-requires resizing cgroups. Always look for a NodeAllocatableEnforced event
-after updating this field to ensure that the update was successful.
Default: nil
-->
@@ -1945,13 +1511,6 @@ When kube-reserved is in the list, kubeReservedCgroup must be speci
This field is supported only when cgroupsPerQOS is set to true.
Refer to Node Allocatable
for more information.
-If DynamicKubeletConfig (deprecated; default off) is on, when
-dynamically updating this field, consider that
-removing enforcements may reduce the stability of the node. Alternatively, adding
-enforcements may reduce the stability of components which were using more than
-the reserved amount of resources; for example, enforcing kube-reserved may cause
-Kubelets to OOM if it uses more than the reserved resources, and enforcing system-reserved
-may cause system daemons to OOM if they use more than the reserved resources.
Default: ["pods"]
-->
+list when the node is shutting down.
+For example, to allow critical pods 10s to shutdown, priority>=10000 pods 20s to
+shutdown, and all remaining pods 30s to shutdown.
+-->
shutdownGracePeriodByPodPriority设置基于 Pod
相关的优先级类值而确定的体面关闭时间。当 kubelet 收到关闭请求的时候,kubelet
会针对节点上运行的所有 Pod 发起关闭操作,这些关闭操作会根据 Pod 的优先级确定其宽限期限,
@@ -2140,6 +1683,15 @@ list when the node is shutting down.-->
-
@@ -1102,7 +1350,7 @@ It does not allow viewing roles or rolebindings.
This role does not allow viewing Secrets, since reading
the contents of Secrets enables access to ServiceAccount credentials
in the namespace, which would allow API access as any ServiceAccount
-in the namespace (a form of privilege escalation).
+in the namespace (a form of privilege escalation).
-->
此角色不允许查看 Secrets,因为读取 Secret 的内容意味着可以访问名字空间中
ServiceAccount 的凭据信息,进而允许利用名字空间中任何 ServiceAccount 的
@@ -1118,7 +1366,7 @@ ServiceAccount 的凭据信息,进而允许利用名字空间中任何 Service
### 核心组件角色 {#core-component-roles}
-
+
system:kube-scheduler 用户
-
允许访问 {{< glossary_tooltip term_id="kube-scheduler" text="scheduler" >}}
@@ -1148,8 +1396,8 @@ Allows access to the resources required by the {{< glossary_tooltip term_id="kub
system:volume-scheduler
-
system:kube-scheduler 用户
@@ -1161,23 +1409,23 @@ Allows access to the volume resources required by the kube-scheduler component.
@@ -1368,10 +1614,10 @@ Allows read access to control-plane monitoring endpoints
The Kubernetes {{< glossary_tooltip term_id="kube-controller-manager" text="controller manager" >}} runs
{{< glossary_tooltip term_id="controller" text="controllers" >}} that are built in to the Kubernetes
control plane.
-When invoked with `-use-service-account-credentials`, kube-controller-manager starts each controller
+When invoked with `--use-service-account-credentials`, kube-controller-manager starts each controller
using a separate service account.
Corresponding roles exist for each built-in controller, prefixed with `system:controller:`.
-If the controller manager is not started with `-use-service-account-credentials`, it runs all control loops
+If the controller manager is not started with `--use-service-account-credentials`, it runs all control loops
using its own credential, which must be granted all the relevant roles.
These roles include:
-->
@@ -1379,12 +1625,12 @@ These roles include:
Kubernetes {{< glossary_tooltip term_id="kube-controller-manager" text="控制器管理器" >}}
运行内建于 Kubernetes 控制面的{{< glossary_tooltip term_id="controller" text="控制器" >}}。
-当使用 `--use-service-account-credentials` 参数启动时, kube-controller-manager
+当使用 `--use-service-account-credentials` 参数启动时,kube-controller-manager
使用单独的服务账户来启动每个控制器。
每个内置控制器都有相应的、前缀为 `system:controller:` 的角色。
如果控制管理器启动时未设置 `--use-service-account-credentials`,
它使用自己的身份凭据来运行所有的控制器,该身份必须被授予所有相关的角色。
-这些角色包括:
+这些角色包括:
* `system:controller:attachdetach-controller`
* `system:controller:certificate-controller`
@@ -1415,12 +1661,12 @@ Kubernetes {{< glossary_tooltip term_id="kube-controller-manager" text="控制
* `system:controller:ttl-controller`
-## 初始化与预防权限提升
+## 初始化与预防权限提升 {#privilege-escalation-prevention-and-bootstrapping}
RBAC API 会阻止用户通过编辑角色或者角色绑定来提升权限。
由于这一点是在 API 级别实现的,所以在 RBAC 鉴权组件未启用的状态下依然可以正常工作。
@@ -1434,7 +1680,7 @@ You can only create/update a role if at least one of the following things is tru
(cluster-wide for a ClusterRole, within the same namespace or cluster-wide for a Role).
2. You are granted explicit permission to perform the `escalate` verb on the `roles` or `clusterroles` resource in the `rbac.authorization.k8s.io` API group.
-->
-### 对角色创建或更新的限制
+### 对角色创建或更新的限制 {#restrictions-on-role-creation-or-update}
只有在符合下列条件之一的情况下,你才能创建/更新角色:
@@ -1470,7 +1716,7 @@ You can only create/update a role binding if you already have all the permission
For example, if `user-1` does not have the ability to list Secrets cluster-wide, they cannot create a ClusterRoleBinding
to a role that grants that permission. To allow a user to create/update role bindings:
-->
-### 对角色绑定创建或更新的限制
+### 对角色绑定创建或更新的限制 {#restrictions-on-role-binding-creation-or-update}
只有你已经具有了所引用的角色中包含的全部权限时,或者你被授权在所引用的角色上执行 `bind`
动词时,你才可以创建或更新角色绑定。这里的权限与角色绑定的作用域相同。
@@ -1495,6 +1741,37 @@ For example, this ClusterRole and RoleBinding would allow `user-1` to grant othe
例如,下面的 ClusterRole 和 RoleBinding 将允许用户 `user-1` 把名字空间 `user-1-namespace`
中的 `admin`、`edit` 和 `view` 角色赋予其他用户:
+
```yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -1529,33 +1806,32 @@ subjects:
When bootstrapping the first roles and role bindings, it is necessary for the initial user to grant permissions they do not yet have.
To bootstrap initial roles and role bindings:
-* Use a credential with the `system:masters` group, which is bound to the `cluster-admin` super-user role by the default bindings.
-* If your API server runs with the insecure port enabled (`-insecure-port`), you can also make API calls via that port, which does not enforce authentication or authorization.
+* Use a credential with the "system:masters" group, which is bound to the "cluster-admin" super-user role by the default bindings.
+* If your API server runs with the insecure port enabled (`--insecure-port`), you can also make API calls via that port, which does not enforce authentication or authorization.
-->
当启动引导第一个角色和角色绑定时,需要为初始用户授予他们尚未拥有的权限。
对初始角色和角色绑定进行初始化时需要:
* 使用用户组为 `system:masters` 的凭据,该用户组由默认绑定关联到 `cluster-admin`
这个超级用户角色。
-* 如果你的 API 服务器启动时启用了不安全端口(使用 `--insecure-port`), 你也可以通过
- 该端口调用 API ,这样的操作会绕过身份验证或鉴权。
+* 如果你的 API 服务器启动时启用了不安全端口(使用 `--insecure-port`),你也可以通过
+ 该端口调用 API,这样的操作会绕过身份验证或鉴权。
+## 一些命令行工具 {#command-line-utilities}
### `kubectl create role`
-Creates a `Role` object defining permissions within a single namespace. Examples:
+
-## 一些命令行工具
-
-### `kubectl create role`
-
创建 Role 对象,定义在某一名字空间中的权限。例如:
-* 创建名称为 "pod-reader" 的 Role 对象,允许用户对 Pods 执行 `get`、`watch` 和 `list` 操作:
+* 创建名称为 “pod-reader” 的 Role 对象,允许用户对 Pods 执行 `get`、`watch` 和 `list` 操作:
```shell
kubectl create role pod-reader --verb=get --verb=list --verb=watch --resource=pods
@@ -1564,16 +1840,16 @@ Creates a `Role` object defining permissions within a single namespace. Examples
-* 创建名称为 "pod-reader" 的 Role 对象并指定 `resourceNames`:
+* 创建名称为 “pod-reader” 的 Role 对象并指定 `resourceNames`:
```shell
kubectl create role pod-reader --verb=get --resource=pods --resource-name=readablepod --resource-name=anotherpod
```
-* 创建名为 "foo" 的 Role 对象并指定 `apiGroups`:
+* 创建名为 “foo” 的 Role 对象并指定 `apiGroups`:
```shell
kubectl create role foo --verb=get,list,watch --resource=replicasets.apps
@@ -1582,7 +1858,7 @@ Creates a `Role` object defining permissions within a single namespace. Examples
-* 创建名为 "foo" 的 Role 对象并指定子资源权限:
+* 创建名为 “foo” 的 Role 对象并指定子资源权限:
```shell
kubectl create role foo --verb=get,list,watch --resource=pods,pods/status
@@ -1591,7 +1867,7 @@ Creates a `Role` object defining permissions within a single namespace. Examples
-* 创建名为 "my-component-lease-holder" 的 Role 对象,使其具有对特定名称的
+* 创建名为 “my-component-lease-holder” 的 Role 对象,使其具有对特定名称的
资源执行 get/update 的权限:
```shell
@@ -1607,7 +1883,7 @@ Creates a ClusterRole. Examples:
-->
创建 ClusterRole 对象。例如:
-* 创建名称为 "pod-reader" 的 ClusterRole`对象,允许用户对 Pods 对象执行 `get`、
+* 创建名称为 “pod-reader” 的 ClusterRole 对象,允许用户对 Pods 对象执行 `get`、
`watch` 和 `list` 操作:
```shell
@@ -1617,7 +1893,7 @@ Creates a ClusterRole. Examples:
-* 创建名为 "pod-reader" 的 ClusterRole 对象并指定 `resourceNames`:
+* 创建名为 “pod-reader” 的 ClusterRole 对象并指定 `resourceNames`:
```shell
kubectl create clusterrole pod-reader --verb=get --resource=pods --resource-name=readablepod --resource-name=anotherpod
@@ -1626,7 +1902,7 @@ Creates a ClusterRole. Examples:
-* 创建名为 "foo" 的 ClusterRole 对象并指定 `apiGroups`:
+* 创建名为 “foo” 的 ClusterRole 对象并指定 `apiGroups`:
```shell
kubectl create clusterrole foo --verb=get,list,watch --resource=replicasets.apps
@@ -1635,7 +1911,7 @@ Creates a ClusterRole. Examples:
-* 创建名为 "foo" 的 ClusterRole 对象并指定子资源:
+* 创建名为 “foo” 的 ClusterRole 对象并指定子资源:
```shell
kubectl create clusterrole foo --verb=get,list,watch --resource=pods,pods/status
@@ -1644,7 +1920,7 @@ Creates a ClusterRole. Examples:
-* 创建名为 "foo" 的 ClusterRole 对象并指定 `nonResourceURL`:
+* 创建名为 “foo” 的 ClusterRole 对象并指定 `nonResourceURL`:
```shell
kubectl create clusterrole "foo" --verb=get --non-resource-url=/logs/*
@@ -1653,7 +1929,7 @@ Creates a ClusterRole. Examples:
-* 创建名为 "monitoring" 的 ClusterRole 对象并指定 `aggregationRule`:
+* 创建名为 “monitoring” 的 ClusterRole 对象并指定 `aggregationRule`:
```shell
kubectl create clusterrole monitoring --aggregation-rule="rbac.example.com/aggregate-to-monitoring=true"
@@ -1668,7 +1944,7 @@ Grants a Role or ClusterRole within a specific namespace. Examples:
-->
在特定的名字空间中对 `Role` 或 `ClusterRole` 授权。例如:
-* 在名字空间 "acme" 中,将名为 `admin` 的 ClusterRole 中的权限授予名称 "bob" 的用户:
+* 在名字空间 “acme” 中,将名为 `admin` 的 ClusterRole 中的权限授予名称 “bob” 的用户:
```shell
kubectl create rolebinding bob-admin-binding --clusterrole=admin --user=bob --namespace=acme
@@ -1677,7 +1953,7 @@ Grants a Role or ClusterRole within a specific namespace. Examples:
-* 在名字空间 "acme" 中,将名为 `view` 的 ClusterRole 中的权限授予名字空间 "acme"
+* 在名字空间 “acme” 中,将名为 `view` 的 ClusterRole 中的权限授予名字空间 “acme”
中名为 `myapp` 的服务账户:
```shell
@@ -1687,8 +1963,8 @@ Grants a Role or ClusterRole within a specific namespace. Examples:
-* 在名字空间 "acme" 中,将名为 `view` 的 ClusterRole 对象中的权限授予名字空间
- "myappnamespace" 中名称为 `myapp` 的服务账户:
+* 在名字空间 “acme” 中,将名为 `view` 的 ClusterRole 对象中的权限授予名字空间
+ “myappnamespace” 中名称为 `myapp` 的服务账户:
```shell
kubectl create rolebinding myappnamespace-myapp-view-binding --clusterrole=view --serviceaccount=myappnamespace:myapp --namespace=acme
@@ -1704,7 +1980,7 @@ Grants a ClusterRole across the entire cluster (all namespaces). Examples:
在整个集群(所有名字空间)中用 ClusterRole 授权。例如:
* 在整个集群范围,将名为 `cluster-admin` 的 ClusterRole 中定义的权限授予名为
- "root" 用户:
+ “root” 用户:
```shell
kubectl create clusterrolebinding root-cluster-admin-binding --clusterrole=cluster-admin --user=root
@@ -1714,7 +1990,7 @@ Grants a ClusterRole across the entire cluster (all namespaces). Examples:
* Across the entire cluster, grant the permissions in the "system:node-proxier" ClusterRole to a user named "system:kube-proxy":
-->
* 在整个集群范围内,将名为 `system:node-proxier` 的 ClusterRole 的权限授予名为
- "system:kube-proxy" 的用户:
+ “system:kube-proxy” 的用户:
```shell
kubectl create clusterrolebinding kube-proxy-binding --clusterrole=system:node-proxier --user=system:kube-proxy
@@ -1723,8 +1999,8 @@ Grants a ClusterRole across the entire cluster (all namespaces). Examples:
-* 在整个集群范围内,将名为 `view` 的 ClusterRole 中定义的权限授予 "acme" 名字空间中
- 名为 "myapp" 的服务账户:
+* 在整个集群范围内,将名为 `view` 的 ClusterRole 中定义的权限授予 “acme” 名字空间中
+ 名为 “myapp” 的服务账户:
```shell
kubectl create clusterrolebinding myapp-view-binding --clusterrole=view --serviceaccount=acme:myapp
@@ -1762,7 +2038,7 @@ Examples:
* 测试应用 RBAC 对象的清单文件,显示将要进行的更改:
```shell
- kubectl auth reconcile -f my-rbac-rules.yaml --dry-run
+ kubectl auth reconcile -f my-rbac-rules.yaml --dry-run=client
```
-* 应用 RBAC 对象的清单文件, 删除角色中的额外权限和绑定中的其他主体:
+* 应用 RBAC 对象的清单文件,删除角色中的额外权限和绑定中的其他主体:
```shell
kubectl auth reconcile -f my-rbac-rules.yaml --remove-extra-subjects --remove-extra-permissions
```
-查看 CLI 帮助获取详细的用法。
-
-
## 服务账户权限 {#service-account-permissions}
@@ -1805,9 +2077,9 @@ Broader grants can give unnecessary (and potentially escalating) API access to s
但是不会对 `kube-system` 名字空间之外的服务账户授予权限。
(除了授予所有已认证用户的发现权限)
-这使得你可以根据需要向特定服务账户授予特定权限。
+这使得你可以根据需要向特定 ServiceAccount 授予特定权限。
细粒度的角色绑定可带来更好的安全性,但需要更多精力管理。
-粗粒度的授权可能导致服务账户被授予不必要的 API 访问权限(甚至导致潜在的权限提升),
+粗粒度的授权可能导致 ServiceAccount 被授予不必要的 API 访问权限(甚至导致潜在的权限提升),
但更易于管理。
这要求应用在其 Pod 规约中指定 `serviceAccountName`,
- 并额外创建服务账户(包括通过 API、应用程序清单、`kubectl create serviceaccount` 等)。
+ 并额外创建服务账户(包括通过 API、应用程序清单、`kubectl create serviceaccount` 等)。
- 例如,在名字空间 "my-namespace" 中授予服务账户 "my-sa" 只读权限:
+ 例如,在名字空间 “my-namespace” 中授予服务账户 “my-sa” 只读权限:
```shell
kubectl create rolebinding my-sa-view \
@@ -1840,7 +2112,7 @@ In order from most secure to least secure, the approaches are:
-2. 将角色授予某名字空间中的 "default" 服务账户
+2. 将角色授予某名字空间中的 “default” 服务账户
- 如果某应用没有指定 `serviceAccountName`,那么它将使用 "default" 服务账户。
+ 如果某应用没有指定 `serviceAccountName`,那么它将使用 “default” 服务账户。
{{< note >}}
"default" 服务账户所具有的权限会被授予给名字空间中所有未指定
@@ -1874,20 +2146,20 @@ In order from most secure to least secure, the approaches are:
To allow those add-ons to run with super-user access, grant cluster-admin
permissions to the "default" service account in the `kube-system` namespace.
- {{< note >}}
+ {{< caution >}}
Enabling this means the `kube-system` namespace contains Secrets
- that grant super-user access to the API.
- {{< /note >}}
+ that grant super-user access to your cluster's API.
+ {{< /caution >}}
-->
- 许多[插件组件](/zh/docs/concepts/cluster-administration/addons/) 在 `kube-system`
- 名字空间以 "default" 服务账户运行。
+ 许多[插件组件](/zh/docs/concepts/cluster-administration/addons/)在 `kube-system`
+ 名字空间以 “default” 服务账户运行。
要允许这些插件组件以超级用户权限运行,需要将集群的 `cluster-admin` 权限授予
- `kube-system` 名字空间中的 "default" 服务账户。
+ `kube-system` 名字空间中的 “default” 服务账户。
- {{< note >}}
- 启用这一配置意味着在 `kube-system` 名字空间中包含以超级用户账号来访问 API
+ {{< caution >}}
+ 启用这一配置意味着在 `kube-system` 名字空间中包含以超级用户账号来访问集群 API
的 Secrets。
- {{< /note >}}
+ {{< /caution >}}
```shell
kubectl create clusterrolebinding add-on-cluster-admin \
@@ -1907,7 +2179,7 @@ In order from most secure to least secure, the approaches are:
如果你想要名字空间中所有应用都具有某角色,无论它们使用的什么服务账户,
可以将角色授予该名字空间的服务账户组。
- 例如,在名字空间 "my-namespace" 中的只读权限授予该名字空间中的所有服务账户:
+ 例如,在名字空间 “my-namespace” 中的只读权限授予该名字空间中的所有服务账户:
```shell
kubectl create rolebinding serviceaccounts-view \
@@ -1949,7 +2221,7 @@ In order from most secure to least secure, the approaches are:
-->
5. 授予超级用户访问权限给集群范围内的所有服务帐户(强烈不鼓励)
- 如果你不关心如何区分权限,你可以将超级用户访问权限授予所有服务账户。
+ 如果你不在乎如何区分权限,你可以将超级用户访问权限授予所有服务账户。
{{< warning >}}
这样做会允许所有应用都对你的集群拥有完全的访问权限,并将允许所有能够读取
@@ -1978,19 +2250,16 @@ guidance for restricting this access in existing clusters.
If you want new clusters to retain this level of access in the aggregated roles,
you can create the following ClusterRole:
-
-{{< codenew file="access/endpoints-aggregated.yaml" >}}
-->
## Endpoints 写权限 {#write-access-for-endpoints}
在 Kubernetes v1.22 之前版本创建的集群里,
-"edit" 和 "admin" 聚合角色包含对 Endpoints 的写权限。
+“edit” 和 “admin” 聚合角色包含对 Endpoints 的写权限。
作为 [CVE-2021-25740](https://github.com/kubernetes/kubernetes/issues/103675) 的缓解措施,
此访问权限不包含在 Kubernetes 1.22 以及更高版本集群的聚合角色里。
升级到 Kubernetes v1.22 版本的现有集群不会包括此变化。
-[CVE 公告](https://github.com/kubernetes/kubernetes/issues/103675)
-包含了在现有集群里限制此访问权限的指引。
+[CVE 公告](https://github.com/kubernetes/kubernetes/issues/103675)包含了在现有集群里限制此访问权限的指引。
如果你希望在新集群的聚合角色里保留此访问权限,你可以创建下面的 ClusterRole:
@@ -2010,7 +2279,7 @@ and controllers, but grant *no permissions* to service accounts outside the `kub
While far more secure, this can be disruptive to existing workloads expecting to automatically receive API permissions.
Here are two approaches for managing this transition:
-->
-## 从 ABAC 升级
+## 从 ABAC 升级 {#upgrading-from-abac}
原来运行较老版本 Kubernetes 的集群通常会使用限制宽松的 ABAC 策略,
包括授予所有服务帐户全权访问 API 的能力。
@@ -2023,19 +2292,19 @@ Here are two approaches for managing this transition:
这里有两种方法来完成这种转换:
### 并行鉴权 {#parallel-authorizers}
-同时运行 RBAC 和 ABAC 鉴权模式, 并指定包含
+同时运行 RBAC 和 ABAC 鉴权模式,并指定包含
[现有的 ABAC 策略](/zh/docs/reference/access-authn-authz/abac/#policy-file-format)
的策略文件:
```shell
---authorization-mode=RBAC,ABAC --authorization-policy-file=mypolicy.json
+--authorization-mode=...,RBAC,ABAC --authorization-policy-file=mypolicy.json
```
-如果 API 服务器启动时,RBAC 组件的日志级别为 5 或更高(`--vmodule=rbac*=5` 或 `--v=5`),
-你可以在 API 服务器的日志中看到 RBAC 的细节 (前缀 `RBAC:`)
+如果 kube-apiserver 启动时,RBAC 组件的日志级别为 5 或更高(`--vmodule=rbac*=5` 或 `--v=5`),
+你可以在 API 服务器的日志中看到 RBAC 拒绝的细节(前缀 `RBAC`)
你可以使用这些信息来确定需要将哪些角色授予哪些用户、组或服务帐户。
-一旦你[将角色授予服务账户](#service-account-permissions) ,工作负载运行时
-在服务器日志中没有出现 RBAC 拒绝消息,就可以删除 ABAC 鉴权器。
+一旦你[将角色授予服务账户](#service-account-permissions)且工作负载运行时,
+服务器日志中没有出现 RBAC 拒绝消息,就可以删除 ABAC 鉴权器。
### 宽松的 RBAC 权限 {#permissive-rbac-permissions}
-你可以使用 RBAC 角色绑定在多个场合使用宽松的策略。
+你可以使用 RBAC 角色绑定复制宽松的 ABAC 策略。
{{< warning >}}
在你完成到 RBAC 的迁移后,应该调整集群的访问控制,确保相关的策略满足你的信息安全需求。
-
From adbf29ff8d86d44d69ee800d8933695d722d0c69 Mon Sep 17 00:00:00 2001
From: Guangwen Feng
Date: Tue, 24 May 2022 15:28:15 +0800
Subject: [PATCH 123/331] [zh] Sync kubelet-credential-provider.md and
downward-api-volume-expose-pod-information.md
Signed-off-by: Guangwen Feng
---
...nward-api-volume-expose-pod-information.md | 168 ++++++++++++------
.../kubelet-credential-provider.md | 61 ++++---
2 files changed, 155 insertions(+), 74 deletions(-)
diff --git a/content/zh/docs/tasks/inject-data-application/downward-api-volume-expose-pod-information.md b/content/zh/docs/tasks/inject-data-application/downward-api-volume-expose-pod-information.md
index 69b0b9ee0d..a8df0ff12b 100644
--- a/content/zh/docs/tasks/inject-data-application/downward-api-volume-expose-pod-information.md
+++ b/content/zh/docs/tasks/inject-data-application/downward-api-volume-expose-pod-information.md
@@ -7,12 +7,15 @@ weight: 40
-此页面描述 Pod 如何使用 DownwardAPIVolumeFile 把自己的信息呈现给 Pod 中运行的容器。
-DownwardAPIVolumeFile 可以呈现 Pod 的字段和容器字段。
+此页面描述 Pod 如何使用
+[`DownwardAPIVolumeFile`](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#downwardapivolumefile-v1-core)
+把自己的信息呈现给 Pod 中运行的容器。
+`DownwardAPIVolumeFile` 可以呈现 Pod 和容器的字段。
## {{% heading "prerequisites" %}}
@@ -26,16 +29,19 @@ DownwardAPIVolumeFile 可以呈现 Pod 的字段和容器字段。
There are two ways to expose Pod and Container fields to a running Container:
* [Environment variables](/docs/tasks/inject-data-application/environment-variable-expose-pod-information/#the-downward-api)
-* Volume Files
+* Volume files
+
+Together, these two ways of exposing Pod and Container fields are called the
+"Downward API".
-->
-## Downward API
+## Downward API {#the-downward-api}
有两种方式可以将 Pod 和 Container 字段呈现给运行中的容器:
* [环境变量](/zh/docs/tasks/inject-data-application/environment-variable-expose-pod-information/#the-downward-api)
* 卷文件
-这两种呈现 Pod 和 Container 字段的方式都称为 *Downward API*。
+这两种呈现 Pod 和 Container 字段的方式都称为 "Downward API"。
-## 存储 Pod 字段
+## 存储 Pod 字段 {#store-pod-fields}
在这个练习中,你将创建一个包含一个容器的 Pod。Pod 的配置文件如下:
@@ -88,7 +94,7 @@ kubectl apply -f https://k8s.io/examples/pods/inject/dapi-volume.yaml
```
验证Pod中的容器运行正常:
@@ -97,7 +103,7 @@ kubectl get pods
```
查看容器的日志:
@@ -120,7 +126,7 @@ builder="john-doe"
```
进入 Pod 中运行的容器,打开一个 Shell:
@@ -194,11 +200,10 @@ total 8
用符号链接可实现元数据的动态原子性刷新;更新将写入一个新的临时目录,
-然后通过使用[rename(2)](http://man7.org/linux/man-pages/man2/rename.2.html)
+然后通过使用 [rename(2)](http://man7.org/linux/man-pages/man2/rename.2.html)
完成 `..data` 符号链接的原子性更新。
-前面的练习中,你将 Pod 字段保存到 DownwardAPIVolumeFile 中。
+## 存储容器字段 {#store-container-fields}
+
+前面的练习中,你将 Pod 字段保存到
+[`DownwardAPIVolumeFile`](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#downwardapivolumefile-v1-core)
+中。
接下来这个练习,你将存储 Container 字段。这里是包含一个容器的 Pod 的配置文件:
{{< codenew file="pods/inject/dapi-volume-resources.yaml" >}}
-在这个配置文件中,你可以看到 Pod 有一个 `downwardAPI` 类型的卷,并且挂载到容器的
-`/etc/podinfo` 目录。
+在这个配置文件中,你可以看到 Pod 有一个
+[`downwardAPI` 卷](/zh/docs/concepts/storage/volumes/#downwardapi),
+并且挂载到容器的 `/etc/podinfo` 目录。
-查看 `downwardAPI` 下面的 `items` 数组。每个数组元素都是一个 DownwardAPIVolumeFile。
+查看 `downwardAPI` 下面的 `items` 数组。每个数组元素都是一个
+[`DownwardAPIVolumeFile`](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#downwardapivolumefile-v1-core)。
-第一个元素指定名为 `client-container` 的容器中 `limits.cpu` 字段的值应保存在名为
-`cpu_limit` 的文件中。
+第一个元素指定在名为 `client-container` 的容器中,
+以 `1m` 所指定格式的 `limits.cpu` 字段的值应保存在名为 `cpu_limit` 的文件中。
+`divisor` 字段是可选的,默认值为 `1`,表示 CPU 的核心和内存的字节。
创建Pod:
@@ -259,7 +273,7 @@ kubectl apply -f https://k8s.io/examples/pods/inject/dapi-volume-resources.yaml
```
打开一个 Shell,进入 Pod 中运行的容器:
@@ -283,39 +297,50 @@ You can use similar commands to view the `cpu_request`, `mem_limit` and
你可以使用同样的命令查看 `cpu_request`、`mem_limit` 和 `mem_request` 文件.
+
+
-## Downward API 的能力
+## Downward API 的能力 {#capabilities-of-the-downward-api}
下面这些信息可以通过环境变量和 `downwardAPI` 卷提供给容器:
* 能通过 `fieldRef` 获得的:
+
* `metadata.name` - Pod 名称
* `metadata.namespace` - Pod 名字空间
* `metadata.uid` - Pod 的 UID
- * `metadata.labels['']` - Pod 标签 `` 的值 (例如, `metadata.labels['mylabel']`)
- * `metadata.annotations['']` - Pod 的注解 `` 的值(例如, `metadata.annotations['myannotation']`)
+ * `metadata.labels['']` - Pod 标签 `` 的值
+ (例如:`metadata.labels['mylabel']`)
+ * `metadata.annotations['']` - Pod 的注解 `` 的值
+ (例如:`metadata.annotations['myannotation']`)
@@ -324,8 +349,10 @@ variables and `downwardAPI` volumes:
* 容器的 CPU 请求值
* 容器的内存约束值
* 容器的内存请求值
- * 容器的巨页限制值(前提是启用了 `DownwardAPIHugePages` [特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/))
- * 容器的巨页请求值(前提是启用了 `DownwardAPIHugePages` [特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/))
+ * 容器的巨页限制值(前提是启用了 `DownwardAPIHugePages`
+ [特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/))
+ * 容器的巨页请求值(前提是启用了 `DownwardAPIHugePages`
+ [特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/))
* 容器的临时存储约束值
* 容器的临时存储请求值
@@ -334,23 +361,33 @@ In addition, the following information is available through
`downwardAPI` volume `fieldRef`:
-->
此外,以下信息可通过 `downwardAPI` 卷从 `fieldRef` 获得:
+
-* `metadata.labels` - Pod 的所有标签,以 `label-key="escaped-label-value"` 格式显示,每行显示一个标签
-* `metadata.annotations` - Pod 的所有注解,以 `annotation-key="escaped-annotation-value"`
- 格式显示,每行显示一个标签
+* `metadata.labels` - Pod 的所有标签,以
+ `label-key="escaped-label-value"` 格式显示,每行显示一个标签
+* `metadata.annotations` - Pod 的所有注解,以
+ `annotation-key="escaped-annotation-value"` 格式显示,每行显示一个标签
以下信息可通过环境变量获得:
-* `status.podIP` - 节点 IP
-* `spec.serviceAccountName` - Pod 服务帐号名称, 版本要求 v1.4.0-alpha.3
-* `spec.nodeName` - 节点名称, 版本要求 v1.4.0-alpha.3
-* `status.hostIP` - 节点 IP, 版本要求 v1.7.0-alpha.1
+* `status.podIP` - Pod IP 地址
+* `spec.serviceAccountName` - Pod 服务帐号名称
+* `spec.nodeName` - 调度器总是尝试将 Pod 调度到的节点的名称
+* `status.hostIP` - Pod 分配到的节点的 IP
-## 投射键名到指定路径并且指定文件权限
+## 投射键名到指定路径并且指定文件权限 {#project-keys-to-specific-paths-and-file-permissions}
你可以将键名投射到指定路径并且指定每个文件的访问权限。
更多信息,请参阅[Secrets](/zh/docs/concepts/configuration/secret/).
@@ -376,7 +413,7 @@ basis. For more information, see
-## Downward API的动机
+## Downward API 的动机 {#motivation-for-the-downward-api}
对于容器来说,有时候拥有自己的信息是很有用的,可避免与 Kubernetes 过度耦合。
Downward API 使得容器使用自己或者集群的信息,而不必通过 Kubernetes 客户端或
@@ -399,9 +436,32 @@ API 服务器来获得。
## {{% heading "whatsnext" %}}
-* [PodSpec](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#podspec-v1-core)
-* [Volume](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#volume-v1-core)
-* [DownwardAPIVolumeSource](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#downwardapivolumesource-v1-core)
-* [DownwardAPIVolumeFile](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#downwardapivolumefile-v1-core)
-* [ResourceFieldSelector](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#resourcefieldselector-v1-core)
+
+* 参阅
+ [`PodSpec`](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#podspec-v1-core)
+ API 定义,该 API 定义 Pod 所需状态。
+* 参阅
+ [`Volume`](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#volume-v1-core)
+ API 定义,该 API 在 Pod 中定义通用卷以供容器访问。
+* 参阅
+ [`DownwardAPIVolumeSource`](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#downwardapivolumesource-v1-core)
+ API 定义,该 API 定义包含 Downward API 信息的卷。
+* 参阅
+ [`DownwardAPIVolumeFile`](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#downwardapivolumefile-v1-core)
+ API 定义,该 API 包含对对象或资源字段的引用,用于在 Downward API 卷中填充文件。
+* 参阅
+ [`ResourceFieldSelector`](/docs/reference/generated/kubernetes-api/{{< param "version" >}}/#resourcefieldselector-v1-core)
+ API 定义,该 API 指定容器资源及其输出格式。
diff --git a/content/zh/docs/tasks/kubelet-credential-provider/kubelet-credential-provider.md b/content/zh/docs/tasks/kubelet-credential-provider/kubelet-credential-provider.md
index eb73c471c3..c888a27177 100644
--- a/content/zh/docs/tasks/kubelet-credential-provider/kubelet-credential-provider.md
+++ b/content/zh/docs/tasks/kubelet-credential-provider/kubelet-credential-provider.md
@@ -48,7 +48,7 @@ This guide demonstrates how to configure the kubelet's image credential provider
* kubelet 镜像凭证提供程序在 v1.20 版本作为 alpha 功能引入。
@@ -73,12 +73,14 @@ every node in your cluster and stored in a known directory. The directory will b
## Configuring the Kubelet
In order to use this feature, the kubelet expects two flags to be set:
+
* `--image-credential-provider-config` - the path to the credential provider plugin config file.
* `--image-credential-provider-bin-dir` - the path to the directory where credential provider plugin binaries are located.
-->
## 配置 kubelet {#configuring-the-kubelet}
为了使用这个特性,kubelet 需要设置以下两个标志:
+
* `--image-credential-provider-config` —— 凭据提供程序插件配置文件的路径。
* `--image-credential-provider-bin-dir` —— 凭据提供程序插件二进制文件所在目录的路径。
@@ -86,18 +88,19 @@ In order to use this feature, the kubelet expects two flags to be set:
### Configure a kubelet credential provider
The configuration file passed into `--image-credential-provider-config` is read by the kubelet to determine which exec plugins
-should be invoked for which container images. Here's an example configuration file you may end up using if you are using the [ECR](https://aws.amazon.com/ecr/)-based plugin:
+should be invoked for which container images. Here's an example configuration file you may end up using if you are using the
+[ECR](https://aws.amazon.com/ecr/)-based plugin:
-->
### 配置 kubelet 凭据提供程序 {#configure-a-kubelet-credential-provider}
-kubelet 会读取传入 `--image-credential-provider-config` 的配置文件文件,
+kubelet 会读取传入 `--image-credential-provider-config` 的配置文件,
以确定应该为哪些容器镜像调用哪些 exec 插件。
-如果你正在使用基于 [ECR](https://aws.amazon.com/ecr/) 插件,
+如果你正在使用基于 [ECR](https://aws.amazon.com/ecr/) 的插件,
这里有个样例配置文件你可能最终会使用到:
```yaml
-kind: CredentialProviderConfig
apiVersion: kubelet.config.k8s.io/v1alpha1
+kind: CredentialProviderConfig
# providers 是将由 kubelet 启用的凭证提供程序插件列表。
# 多个提供程序可能与单个镜像匹配,在这种情况下,来自所有提供程序的凭据将返回到 kubelet。
# 如果为单个镜像调用多个提供程序,则结果会合并。
@@ -130,11 +133,11 @@ providers:
# - *.*.registry.io
# - registry.io:8080/path
matchImages:
- - "*.dkr.ecr.*.amazonaws.com"
- - "*.dkr.ecr.*.amazonaws.cn"
- - "*.dkr.ecr-fips.*.amazonaws.com"
- - "*.dkr.ecr.us-iso-east-1.c2s.ic.gov"
- - "*.dkr.ecr.us-isob-east-1.sc2s.sgov.gov"
+ - "*.dkr.ecr.*.amazonaws.com"
+ - "*.dkr.ecr.*.amazonaws.cn"
+ - "*.dkr.ecr-fips.*.amazonaws.com"
+ - "*.dkr.ecr.us-iso-east-1.c2s.ic.gov"
+ - "*.dkr.ecr.us-isob-east-1.sc2s.sgov.gov"
# defaultCacheDuration 是插件将在内存中缓存凭据的默认持续时间
# 如果插件响应中未提供缓存持续时间。此字段是必需的。
defaultCacheDuration: "12h"
@@ -145,30 +148,36 @@ providers:
# 执行命令时传递给命令的参数。
# +可选
args:
- - get-credentials
+ - get-credentials
# env 定义了额外的环境变量以暴露给进程。
# 这些与主机环境以及 client-go 用于将参数传递给插件的变量结合在一起。
# +可选
env:
- - name: AWS_PROFILE
- value: example_profile
+ - name: AWS_PROFILE
+ value: example_profile
```
`providers` 字段是 kubelet 使用的已启用插件列表。每个条目都有几个必填字段:
+
* `name`:插件的名称,必须与传入`--image-credential-provider-bin-dir`
的目录中存在的可执行二进制文件的名称相匹配。
-* `matchImages`:用于匹配图像以确定是否应调用此提供程序的字符串列表。更多相关信息如下。
+* `matchImages`:用于匹配镜像以确定是否应调用此提供程序的字符串列表。更多相关信息如下。
* `defaultCacheDuration`:如果插件未指定缓存持续时间,kubelet 将在内存中缓存凭据的默认持续时间。
-* `apiVersion`:kubelet 和 exec 插件在通信时将使用的 api 版本。
+* `apiVersion`:kubelet 和 exec 插件在通信时将使用的 API 版本。
每个凭证提供程序也可以被赋予可选的参数和环境变量。
咨询插件实现者以确定给定插件需要哪些参数和环境变量集。
@@ -207,8 +216,20 @@ Some example values of `matchImages` patterns are:
* 如果 imageMatch 包含端口,则该端口也必须在镜像中匹配。
`matchImages` 模式的一些示例值:
+
* `123456789.dkr.ecr.us-east-1.amazonaws.com`
* `*.azurecr.io`
* `gcr.io`
* `*.*.registry.io`
* `foo.registry.io:8080/path`
+
+## {{% heading "whatsnext" %}}
+
+
+* 阅读 [kubelet 配置 API (v1alpha1) 参考](/zh/docs/reference/config-api/kubelet-config.v1alpha1/)中有关 `CredentialProviderConfig` 的详细信息。
+* 阅读 [kubelet 凭据提供程序 API 参考 (v1alpha1)](/docs/reference/config-api/kubelet-credentialprovider.v1alpha1/)。
+
From 1ef57ccad261d21c728a15e9975ec974938deca0 Mon Sep 17 00:00:00 2001
From: Debanitrkl <118bm0622@nitrkl.ac.in>
Date: Wed, 25 May 2022 11:26:08 +0530
Subject: [PATCH 124/331] Follow up updates to release blog regarding CSI
Snapshot
---
content/en/blog/_posts/2022-05-03-kubernetes-release-1.24.md | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/content/en/blog/_posts/2022-05-03-kubernetes-release-1.24.md b/content/en/blog/_posts/2022-05-03-kubernetes-release-1.24.md
index 7c0486478f..c0c47fd759 100644
--- a/content/en/blog/_posts/2022-05-03-kubernetes-release-1.24.md
+++ b/content/en/blog/_posts/2022-05-03-kubernetes-release-1.24.md
@@ -118,6 +118,11 @@ With containerd v1.6.0–v1.6.3, if you do not upgrade the CNI plugins and/or
declare the CNI config version, you might encounter the following "Incompatible
CNI versions" or "Failed to destroy network for sandbox" error conditions.
+## CSI Snapshot
+
+[VolumeSnapshot v1beta1 CRD has been removed](https://github.com/kubernetes/enhancements/issues/177).
+Volume snapshot and restore functionality for Kubernetes and the Container Storage Interface (CSI), which provides standardized APIs design (CRDs) and adds PV snapshot/restore support for CSI volume drivers, entered beta in v1.20. VolumeSnapshot v1beta1 was deprecated in v1.21 and is now unsupported. Refer to [KEP-177: CSI Snapshot](https://github.com/kubernetes/enhancements/tree/master/keps/sig-storage/177-volume-snapshot#kep-177-csi-snapshot) and [kubernetes-csi/external-snapshotter](https://github.com/kubernetes-csi/external-snapshotter/releases/tag/v4.1.0) for more information.
+
## Other Updates
### Graduations to Stable
From 5dddab2997f1fce01dc5b6d32ecffa85f5b1dcd2 Mon Sep 17 00:00:00 2001
From: Paco Xu
Date: Wed, 25 May 2022 14:46:23 +0800
Subject: [PATCH 125/331] fix wrong number in
service-ip-dynamic-and-static-allocation
---
.../2022-05-23-service-ip-dynamic-and-static-allocation.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/en/blog/_posts/2022-05-23-service-ip-dynamic-and-static-allocation.md b/content/en/blog/_posts/2022-05-23-service-ip-dynamic-and-static-allocation.md
index 92120605a2..e67d173bc0 100644
--- a/content/en/blog/_posts/2022-05-23-service-ip-dynamic-and-static-allocation.md
+++ b/content/en/blog/_posts/2022-05-23-service-ip-dynamic-and-static-allocation.md
@@ -101,7 +101,7 @@ pie showData
#### Service IP CIDR block: 10.96.0.0/20
Range Size: 212 - 2 = 4094
-Band Offset: `min(max(16,256/16),256)` = `min(256,256)` = 256
+Band Offset: `min(max(16,4096/16),256)` = `min(256,256)` = 256
Static band start: 10.96.0.1
Static band end: 10.96.1.0
Range end: 10.96.15.254
From 60c571656761253a4f616647b16b3e1ed8d07cf4 Mon Sep 17 00:00:00 2001
From: Tom Kivlin
Date: Wed, 25 May 2022 08:20:25 +0100
Subject: [PATCH 126/331] capitalisation consistency
---
.../compute-storage-net/network-plugins.md | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/content/en/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins.md b/content/en/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins.md
index 4c09ad1043..52b0bc3e26 100644
--- a/content/en/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins.md
+++ b/content/en/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins.md
@@ -29,8 +29,8 @@ CNI specification (plugins can be compatible with multiple spec versions).
A Container Runtime, in the networking context, is a daemon on a node configured to provide CRI Services for kubelet. In particular, the Container Runtime must be configured to load the CNI plugins required to implement the Kubernetes network model.
{{< note >}}
-Prior to Kubernetes 1.24, the CNI plugins could also be managed by the Kubelet using the `cni-bin-dir` and `network-plugin` command-line parameters.
-These command-line parameters were removed in Kubernetes 1.24, with management of the CNI no longer in scope for Kubelet.
+Prior to Kubernetes 1.24, the CNI plugins could also be managed by the kubelet using the `cni-bin-dir` and `network-plugin` command-line parameters.
+These command-line parameters were removed in Kubernetes 1.24, with management of the CNI no longer in scope for kubelet.
See [Troubleshooting CNI plugin-related errors](/docs/tasks/administer-cluster/migrating-from-dockershim/troubleshooting-cni-plugin-related-errors/)
if you are facing issues following the removal of dockershim.
@@ -53,8 +53,8 @@ By default, if no kubelet network plugin is specified, the `noop` plugin is used
### Loopback CNI
-In addition to the CNI plugin installed on the nodes for implementing the Kubernetes Network Model, Kubernetes also requires the Container Runtimes to provide a loopback interface `lo`, which is used for each sandbox (pod sandboxes, vm sandboxes, ...).
-Implementing the loopback interface can be accomplished by re-using the [`the CNI loopback plugin.`](https://github.com/containernetworking/plugins/blob/master/plugins/main/loopback/loopback.go) or by developing your own code to achieve this (see [this example from CRI-O](https://github.com/cri-o/ocicni/blob/release-1.24/pkg/ocicni/util_linux.go#L91)).
+In addition to the CNI plugin installed on the nodes for implementing the Kubernetes network model, Kubernetes also requires the container runtimes to provide a loopback interface `lo`, which is used for each sandbox (pod sandboxes, vm sandboxes, ...).
+Implementing the loopback interface can be accomplished by re-using the [the CNI loopback plugin.](https://github.com/containernetworking/plugins/blob/master/plugins/main/loopback/loopback.go) or by developing your own code to achieve this (see [this example from CRI-O](https://github.com/cri-o/ocicni/blob/release-1.24/pkg/ocicni/util_linux.go#L91)).
### Support hostPort
From 86cada932dc0c680080d7ced29b6d39694d63ca7 Mon Sep 17 00:00:00 2001
From: Sean Wei
Date: Wed, 25 May 2022 17:30:00 +0800
Subject: [PATCH 127/331] [zh] Sync kube-scheduler.md
---
.../kube-scheduler.md | 262 ++++++++----------
1 file changed, 121 insertions(+), 141 deletions(-)
diff --git a/content/zh/docs/reference/command-line-tools-reference/kube-scheduler.md b/content/zh/docs/reference/command-line-tools-reference/kube-scheduler.md
index 0da24c1f84..28fb4f2a61 100644
--- a/content/zh/docs/reference/command-line-tools-reference/kube-scheduler.md
+++ b/content/zh/docs/reference/command-line-tools-reference/kube-scheduler.md
@@ -2,7 +2,6 @@
title: kube-scheduler
content_type: tool-reference
weight: 30
-auto_generated: true
---
Kubernetes 调度器是一个控制面进程,负责将 Pods 指派到节点上。
调度器基于约束和可用资源为调度队列中每个 Pod 确定其可合法放置的节点。
调度器之后对所有合法的节点进行排序,将 Pod 绑定到一个合适的节点。
在同一个集群中可以使用多个不同的调度器;kube-scheduler 是其参考实现。
-参阅[调度](zh/docs/concepts/scheduling-eviction/)
-以获得关于调度和 kube-scheduler 组件的更多信息。
+参阅[调度](/zh/docs/concepts/scheduling-eviction/)以获得关于调度和
+kube-scheduler 组件的更多信息。
```
kube-scheduler [flags]
@@ -47,14 +46,14 @@ kube-scheduler [flags]
--allow-metric-labels stringToString
-默认值: []
+默认值:[]
-这个键值映射表设置 度量标签 所允许设置的值。
+这个键值映射表设置度量标签所允许设置的值。
其中键的格式是 <MetricName>,<LabelName>。
值的格式是 <allowed_value>,<allowed_value>。
例如:metric1,label1='v1,v2,v3', metric1,label2='v1,v2,v3' metric2,label1='v1,v2,v3'。
@@ -120,7 +119,7 @@ If true, failures to look up missing authentication configuration from the clust
-在授权过程中跳过的 HTTP 路径列表,即在不联系 'core' kubernetes 服务器的情况下被授权的 HTTP 路径。
+在授权过程中跳过的 HTTP 路径列表,即在不联系 “core” kubernetes 服务器的情况下被授权的 HTTP 路径。
@@ -158,7 +157,7 @@ The duration to cache 'authorized' responses from the webhook authorizer.
-缓存来自 Webhook 授权者的 'unauthorized' 响应的持续时间。
+缓存来自 Webhook 授权者的 “unauthorized” 响应的持续时间。
@@ -184,7 +183,7 @@ The IP address on which to listen for the --secure-port port. The associated int
-->
监听 --secure-port 端口的 IP 地址。
集群的其余部分以及 CLI/ Web 客户端必须可以访问关联的接口。
-如果为空,将使用所有接口(0.0.0.0 表示使用所有 IPv4 接口,"::" 表示使用所有 IPv6 接口)。
+如果为空,将使用所有接口(0.0.0.0 表示使用所有 IPv4 接口,“::” 表示使用所有 IPv6 接口)。
如果为空或未指定地址 (0.0.0.0 或 ::),所有接口将被使用。
@@ -228,7 +227,7 @@ The path to the configuration file.
@@ -534,7 +516,7 @@ DEPRECATED: content type of requests sent to apiserver. This parameter is ignore
-
--kube-api-qps float32 默认值:50
+
--kube-api-qps float 默认值:50
@@ -745,7 +727,7 @@ If true, SO_REUSEADDR will be used when binding the port. This allows binding to
如果为 true,在绑定端口时将使用 SO_REUSEADDR。
这将允许同时绑定诸如 0.0.0.0 这类通配符 IP和特定 IP,
并且它避免等待内核释放处于 TIME_WAIT 状态的套接字。
-默认值: false
+默认值:false
@@ -758,7 +740,7 @@ If true, SO_REUSEADDR will be used when binding the port. This allows binding to
If true, SO_REUSEPORT will be used when binding the port, which allows more than one instance to bind on the same address and port. [default=false]
-->
如果此标志为 true,在绑定端口时会使用 SO_REUSEPORT,从而允许不止一个
-实例绑定到同一地址和端口。
+实例绑定到同一地址和端口。
默认值:false
@@ -781,7 +763,7 @@ unschedulablePods 移动到 backoffQ 或 activeQ。
-
--profiling 默认值: true
+
--profiling 默认值:true
@@ -824,7 +806,7 @@ Root certificate bundle to use to verify client certificates on incoming request
@@ -897,7 +879,7 @@ The previous version for which you want to show hidden metrics. Only the previou
-包含默认的 HTTPS x509 证书的文件。(CA证书(如果有)在服务器证书之后并置)。
+包含默认的 HTTPS x509 证书的文件。(如果有 CA 证书,在服务器证书之后并置)。
如果启用了 HTTPS 服务,并且未提供 --tls-cert-file 和
--tls-private-key-file,则会为公共地址生成一个自签名证书和密钥,
并将其保存到 --cert-dir 指定的目录中。
@@ -962,7 +944,7 @@ A pair of x509 certificate and private key file paths, optionally suffixed with
如果未提供域名匹配模式,则提取证书名称。
非通配符匹配优先于通配符匹配,显式域名匹配优先于提取而来的名称。
若有多个密钥/证书对,可多次使用 --tls-sni-cert-key。
-例子: "example.crt,example.key" 或者 "foo.crt,foo.key:*.foo.com,foo.com"。
+例如: "example.crt,example.key" 或者 "foo.crt,foo.key:*.foo.com,foo.com"。
@@ -998,7 +980,7 @@ Print version information and quit
-以逗号分隔的 ‘模式=N’ 设置列表,用于文件过滤的日志记录(仅适用于文本日志格式)。
+以逗号分隔的 “pattern=N” 设置列表,用于文件过滤的日志记录(仅适用于文本日志格式)。
@@ -1010,7 +992,7 @@ comma-separated list of pattern=N settings for file-filtered logging (only works
-如果已设置,将配置值写入此文件并退出。
+如果设置此参数,将配置值写入此文件并退出。
@@ -1019,5 +1001,3 @@ If set, write the configuration values to this file and exit.
-
-
From b2a646a158f50325d0f4a12c7bc9ec00bd6a2732 Mon Sep 17 00:00:00 2001
From: Mengjiao Liu
Date: Mon, 23 May 2022 16:14:39 +0800
Subject: [PATCH 128/331] [zh] Sync 1.24 concepts-3
---
.../concepts/storage/persistent-volumes.md | 128 +++++++++++---
content/zh/docs/concepts/storage/volumes.md | 162 +++++++-----------
2 files changed, 159 insertions(+), 131 deletions(-)
diff --git a/content/zh/docs/concepts/storage/persistent-volumes.md b/content/zh/docs/concepts/storage/persistent-volumes.md
index fdf9e6ee50..96c585fb72 100644
--- a/content/zh/docs/concepts/storage/persistent-volumes.md
+++ b/content/zh/docs/concepts/storage/persistent-volumes.md
@@ -374,6 +374,97 @@ However, the particular path specified in the custom recycler Pod template in th
定制回收器 Pod 模板中在 `volumes` 部分所指定的特定路径要替换为
正被回收的卷的路径。
+
+### PersistentVolume 删除保护 finalizer {#persistentvolume-deletion-protection-finalizer}
+{{< feature-state for_k8s_version="v1.23" state="alpha" >}}
+
+可以在 PersistentVolume 上添加终结器(Finalizers),以确保只有在删除对应的存储后才删除具有
+`Delete` 回收策略的 PersistentVolume。
+
+
+新引入的 `kubernetes.io/pv-controller` 和 `external-provisioner.volume.kubernetes.io/finalizer`
+终结器仅会被添加到动态制备的卷上。
+
+终结器 `kubernetes.io/pv-controller` 会被添加到树内插件卷上。
+下面是一个例子:
+
+```shell
+kubectl describe pv pvc-74a498d6-3929-47e8-8c02-078c1ece4d78
+Name: pvc-74a498d6-3929-47e8-8c02-078c1ece4d78
+Labels:
+Annotations: kubernetes.io/createdby: vsphere-volume-dynamic-provisioner
+ pv.kubernetes.io/bound-by-controller: yes
+ pv.kubernetes.io/provisioned-by: kubernetes.io/vsphere-volume
+Finalizers: [kubernetes.io/pv-protection kubernetes.io/pv-controller]
+StorageClass: vcp-sc
+Status: Bound
+Claim: default/vcp-pvc-1
+Reclaim Policy: Delete
+Access Modes: RWO
+VolumeMode: Filesystem
+Capacity: 1Gi
+Node Affinity:
+Message:
+Source:
+ Type: vSphereVolume (a Persistent Disk resource in vSphere)
+ VolumePath: [vsanDatastore] d49c4a62-166f-ce12-c464-020077ba5d46/kubernetes-dynamic-pvc-74a498d6-3929-47e8-8c02-078c1ece4d78.vmdk
+ FSType: ext4
+ StoragePolicyName: vSAN Default Storage Policy
+Events:
+```
+
+
+终结器 `external-provisioner.volume.kubernetes.io/finalizer` 会被添加到 CSI 卷上。下面是一个例子:
+
+```shell
+Name: pvc-2f0bab97-85a8-4552-8044-eb8be45cf48d
+Labels:
+Annotations: pv.kubernetes.io/provisioned-by: csi.vsphere.vmware.com
+Finalizers: [kubernetes.io/pv-protection external-provisioner.volume.kubernetes.io/finalizer]
+StorageClass: fast
+Status: Bound
+Claim: demo-app/nginx-logs
+Reclaim Policy: Delete
+Access Modes: RWO
+VolumeMode: Filesystem
+Capacity: 200Mi
+Node Affinity:
+Message:
+Source:
+ Type: CSI (a Container Storage Interface (CSI) volume source)
+ Driver: csi.vsphere.vmware.com
+ FSType: ext4
+ VolumeHandle: 44830fa8-79b4-406b-8b58-621ba25353fd
+ ReadOnly: false
+ VolumeAttributes: storage.kubernetes.io/csiProvisionerIdentity=1648442357185-8081-csi.vsphere.vmware.com
+ type=vSphere CNS Block Volume
+Events:
+```
+
+
+为特定的树内卷插件启用 `CSIMigration` 特性将删除 `kubernetes.io/pv-controller` 终结器,
+同时添加 `external-provisioner.volume.kubernetes.io/finalizer` 终结器。
+同样,禁用 `CSIMigration` 将删除 `external-provisioner.volume.kubernetes.io/finalizer` 终结器,
+同时添加 `kubernetes.io/pv-controller` 终结器。
+
#### 重设使用中 PVC 申领的大小 {#resizing-an-in-use-persistentvolumevlaim}
-{{< feature-state for_k8s_version="v1.15" state="beta" >}}
-
-
-{{< note >}}
-Kubernetes 从 1.15 版本开始将调整使用中 PVC 申领大小这一能力作为 Beta
-特性支持;该特性在 1.11 版本以来处于 Alpha 阶段。
-`ExpandInUsePersistentVolumes` 特性必须被启用;在很多集群上,与此类似的
-Beta 阶段的特性是自动启用的。
-可参考[特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)
-文档了解更多信息。
-{{< /note >}}
+{{< feature-state for_k8s_version="v1.24" state="stable" >}}
{{< note >}}
Kubernetes 从 1.23 版本开始将允许用户恢复失败的 PVC 扩展这一能力作为
-alpha 特性支持。 `RecoverVolumeExpansionFailure` 必须被启用以允许使用此功能。
+alpha 特性支持。 `RecoverVolumeExpansionFailure` 必须被启用以允许使用此特性。
可参考[特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)
文档了解更多信息。
{{< /note >}}
-如果集群中的特性门控 `ExpandPersistentVolumes` 和 `RecoverVolumeExpansionFailure`
-都已启用,在 PVC 的扩展发生失败时,你可以使用比先前请求的值更小的尺寸来重试扩展。
+如果集群中的特性门控 `RecoverVolumeExpansionFailure`
+已启用,在 PVC 的扩展发生失败时,你可以使用比先前请求的值更小的尺寸来重试扩展。
要使用一个更小的尺寸尝试请求新的扩展,请编辑该 PVC 的 `.spec.resources` 并选择
一个比你之前所尝试的值更小的值。
如果由于容量限制而无法成功扩展至更高的值,这将很有用。
@@ -1411,10 +1490,7 @@ spec:
## Volume populators and data sources
-Kubernetes supports custom volume populators; this alpha feature was introduced
-in Kubernetes 1.18. Kubernetes 1.22 reimplemented the mechanism with a redesigned API.
-Check that you are reading the version of the Kubernetes documentation that matches your
-cluster. {{% version-check %}}
+Kubernetes supports custom volume populators.
To use custom volume populators, you must enable the `AnyVolumeDataSource`
[feature gate](/docs/reference/command-line-tools-reference/feature-gates/) for
the kube-apiserver and kube-controller-manager.
@@ -1428,13 +1504,11 @@ gate enabled, use of the `dataSourceRef` is preferred over `dataSource`.
## 卷填充器(Populator)与数据源 {#volume-populators-and-data-sources}
-{{< feature-state for_k8s_version="v1.22" state="alpha" >}}
+{{< feature-state for_k8s_version="v1.24" state="beta" >}}
{{< note >}}
-Kubernetes 支持自定义的卷填充器;Kubernetes 1.18 版本引入了这个 alpha 特性。
-Kubernetes 1.22 使用重新设计的 API 重新实现了该机制。
-确认你正在阅读与你的集群版本一致的 Kubernetes 文档。{{% version-check %}}
-要使用自定义的卷填充器,你必须为 kube-apiserver 和 kube-controller-manager 启用 `AnyVolumeDataSource`
+Kubernetes 支持自定义的卷填充器;要使用自定义的卷填充器,你必须为
+kube-apiserver 和 kube-controller-manager 启用 `AnyVolumeDataSource`
[特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)。
{{< /note >}}
@@ -1630,7 +1704,7 @@ Volume snapshot feature was added to support CSI Volume Plugins only. For detail
To enable support for restoring a volume from a volume snapshot data source, enable the
`VolumeSnapshotDataSource` feature gate on the apiserver and controller-manager.
-->
-卷快照(Volume Snapshot)功能的添加仅是为了支持 CSI 卷插件。
+卷快照(Volume Snapshot)特性的添加仅是为了支持 CSI 卷插件。
有关细节可参阅[卷快照](/zh/docs/concepts/storage/volume-snapshots/)文档。
要启用从卷快照数据源恢复数据卷的支持,可在 API 服务器和控制器管理器上启用
diff --git a/content/zh/docs/concepts/storage/volumes.md b/content/zh/docs/concepts/storage/volumes.md
index 2d92dbf79c..f70172c0a2 100644
--- a/content/zh/docs/concepts/storage/volumes.md
+++ b/content/zh/docs/concepts/storage/volumes.md
@@ -256,22 +256,21 @@ For more details, see the [`azureDisk` volume plugin](https://github.com/kuberne
-->
#### azureDisk 的 CSI 迁移 {#azuredisk-csi-migration}
-{{< feature-state for_k8s_version="v1.19" state="beta" >}}
+{{< feature-state for_k8s_version="v1.24" state="stable" >}}
-启用 `azureDisk` 的 `CSIMigration` 功能后,所有插件操作从现有的树内插件重定向到
+启用 `azureDisk` 的 `CSIMigration` 特性后,所有插件操作从现有的树内插件重定向到
`disk.csi.azure.com` 容器存储接口(CSI)驱动程序。
-为了使用此功能,必须在集群中安装
+为了使用此特性,必须在集群中安装
[Azure 磁盘 CSI 驱动程序](https://github.com/kubernetes-sigs/azuredisk-csi-driver),
-并且 `CSIMigration` 和 `CSIMigrationAzureDisk` 功能必须被启用。
+并且 `CSIMigration` 特性必须被启用。
-启用 `azureFile` 的 `CSIMigration` 功能后,所有插件操作将从现有的树内插件重定向到
-`file.csi.azure.com` 容器存储接口(CSI)驱动程序。要使用此功能,必须在集群中安装
+启用 `azureFile` 的 `CSIMigration` 特性后,所有插件操作将从现有的树内插件重定向到
+`file.csi.azure.com` 容器存储接口(CSI)驱动程序。要使用此特性,必须在集群中安装
[Azure 文件 CSI 驱动程序](https://github.com/kubernetes-sigs/azurefile-csi-driver),
并且 `CSIMigration` 和 `CSIMigrationAzureFile`
[特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)
必须被启用。
Azure 文件 CSI 驱动尚不支持为同一卷设置不同的 fsgroup。
-如果 AzureFile CSI 迁移被启用,用不同的 fsgroup 来使用同一卷也是不被支持的。
+如果 `CSIMigrationAzureFile` 特性被启用,用不同的 fsgroup 来使用同一卷也是不被支持的。
#### OpenStack CSI 迁移
-{{< feature-state for_k8s_version="v1.21" state="beta" >}}
+{{< feature-state for_k8s_version="v1.24" state="stable" >}}
-Cinder 的 `CSIMigration` 功能在 Kubernetes 1.21 版本中是默认被启用的。
+自 Kubernetes 1.21 版本起,Cinder 的 `CSIMigration` 特性是默认被启用的。
此特性会将插件的所有操作从现有的树内插件重定向到
`cinder.csi.openstack.org` 容器存储接口(CSI)驱动程序。
-为了使用此功能,必须在集群中安装
+为了使用此特性,必须在集群中安装
[OpenStack Cinder CSI 驱动程序](https://github.com/kubernetes/cloud-provider-openstack/blob/master/docs/cinder-csi-plugin/using-cinder-csi-plugin.md),
你可以通过设置 `CSIMigrationOpenStack`
[特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)
为 `false` 来禁止 Cinder CSI 迁移。
-如果你禁用了 `CSIMigrationOpenStack` 功能特性,则树内的 Cinder 卷插件
-会负责 Cinder 卷存储管理的方方面面。
+
+
+要禁止控制器管理器和 kubelet 加载树内 Cinder 插件,你可以启用
+`InTreePluginOpenStackUnregister` [特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)。
### configMap
@@ -783,8 +785,8 @@ within the same region. In order to use this feature, the volume must be provisi
as a PersistentVolume; referencing the volume directly from a Pod is not supported.
-->
[区域持久盘](https://cloud.google.com/compute/docs/disks/#repds)
-功能允许你创建能在同一区域的两个可用区中使用的持久盘。
-要使用这个功能,必须以持久卷(PersistentVolume)的方式提供卷;直接从
+特性允许你创建能在同一区域的两个可用区中使用的持久盘。
+要使用这个特性,必须以持久卷(PersistentVolume)的方式提供卷;直接从
Pod 引用这种卷是不可以的。
-启用 GCE PD 的 `CSIMigration` 功能后,所有插件操作将从现有的树内插件重定向到
+启用 GCE PD 的 `CSIMigration` 特性后,所有插件操作将从现有的树内插件重定向到
`pd.csi.storage.gke.io` 容器存储接口( CSI )驱动程序。
-为了使用此功能,必须在集群中上安装
+为了使用此特性,必须在集群中上安装
[GCE PD CSI驱动程序](https://github.com/kubernetes-sigs/gcp-compute-persistent-disk-csi-driver),
-并且 `CSIMigration` 和 `CSIMigrationGCE` Beta 功能必须被启用。
+并且 `CSIMigration` 和 `CSIMigrationGCE` Beta 特性必须被启用。
-启用 RBD 的 `CSIMigration` 功能后,所有插件操作从现有的树内插件重定向到
+启用 RBD 的 `CSIMigration` 特性后,所有插件操作从现有的树内插件重定向到
`rbd.csi.ceph.com` {{}} 驱动程序。
-要使用该功能,必须在集群内安装
+要使用该特性,必须在集群内安装
[Ceph CSI 驱动](https://github.com/ceph/ceph-csi),并启用 `CSIMigration` 和 `csiMigrationRBD`
[特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)。
@@ -1601,15 +1603,13 @@ For more information about StorageOS, dynamic provisioning, and PersistentVolume
关于 StorageOS 的进一步信息、动态供应和持久卷申领等等,请参考
[StorageOS 示例](https://github.com/kubernetes/examples/blob/master/volumes/storageos)。
-### vsphereVolume {#vspherevolume}
+### vsphereVolume(弃用) {#vspherevolume}
{{< note >}}
-你必须配置 Kubernetes 的 vSphere 云驱动。云驱动的配置方法请参考
-[vSphere 使用指南](https://vmware.github.io/vsphere-storage-for-kubernetes/documentation/)。
+建议你改用 vSphere CSI 树外驱动程序。
{{< /note >}}
-{{< caution >}}
-在挂载到 Pod 之前,你必须用下列方式之一创建 VMDK。
-{{< /caution >}}
-
-
-#### 创建 VMDK 卷 {#creating-vmdk-volume}
-
-选择下列方式之一创建 VMDK。
-
-{{< tabs name="tabs_volumes" >}}
-{{% tab name="使用 vmkfstools 创建" %}}
-
-首先 ssh 到 ESX,然后使用下面的命令来创建 VMDK:
-
-```shell
-vmkfstools -c 2G /vmfs/volumes/DatastoreName/volumes/myDisk.vmdk
-```
-{{% /tab %}}
-{{% tab name="使用 vmware-vdiskmanager 创建" %}}
-
-使用下面的命令创建 VMDK:
-
-```shell
-vmware-vdiskmanager -c -t 0 -s 40GB -a lsilogic myDisk.vmdk
-```
-{{% /tab %}}
-
-{{< /tabs >}}
-
-
-
-#### vSphere VMDK 配置示例 {#vsphere-vmdk-configuration}
-
-```yaml
-apiVersion: v1
-kind: Pod
-metadata:
- name: test-vmdk
-spec:
- containers:
- - image: k8s.gcr.io/test-webserver
- name: test-container
- volumeMounts:
- - mountPath: /test-vmdk
- name: test-volume
- volumes:
- - name: test-volume
- # 此 VMDK 卷必须已经存在
- vsphereVolume:
- volumePath: "[DatastoreName] volumes/myDisk"
- fsType: ext4
-```
-
@@ -1710,10 +1648,26 @@ must be installed on the cluster and the `CSIMigration` and `CSIMigrationvSphere
[特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)。
-此特性还要求 vSphere vCenter/ESXi 的版本至少为 7.0u1,且 HW 版本至少为
-VM version 15。
+你可以在 VMware 的文档页面
+[迁移树内 vSphere 卷插件到 vSphere 容器存储插件](https://docs.vmware.com/en/VMware-vSphere-Container-Storage-Plug-in/2.0/vmware-vsphere-csp-getting-started/GUID-968D421F-D464-4E22-8127-6CB9FF54423F.html)
+中找到有关如何迁移的其他建议。
+
+为了迁移到树外 CSI 驱动程序,Kubernetes v{{< skew currentVersion >}}
+要求你使用 vSphere 7.0u2 或更高版本。
+如果你正在运行 v{{< skew currentVersion >}} 以外的 Kubernetes 版本,
+请查阅该 Kubernetes 版本的文档。
+如果你正在运行 Kubernetes v{{< skew currentVersion >}} 和旧版本的 vSphere,
+请考虑至少升级到 vSphere 7.0u2。
{{< note >}}
-Kubernetes 1.23 中加入了 Portworx 的 `CSIMigration` 功能,但默认不会启用,因为该功能仍处于 alpha 阶段。
-该功能会将所有的插件操作从现有的树内插件重定向到
+Kubernetes 1.23 中加入了 Portworx 的 `CSIMigration` 特性,但默认不会启用,因为该特性仍处于 alpha 阶段。
+该特性会将所有的插件操作从现有的树内插件重定向到
`pxd.portworx.com` 容器存储接口(Container Storage Interface, CSI)驱动程序。
集群中必须安装
[Portworx CSI 驱动](https://docs.portworx.com/portworx-install-with-kubernetes/storage-operations/csi/)。
-要启用此功能,请在 kube-controller-manager 和 kubelet 中设置 `CSIMigrationPortworx=true`。
+要启用此特性,请在 kube-controller-manager 和 kubelet 中设置 `CSIMigrationPortworx=true`。
-启用 `CSIMigration` 功能后,针对现有树内插件的操作会被重定向到相应的 CSI 插件(应已安装和配置)。
+启用 `CSIMigration` 特性后,针对现有树内插件的操作会被重定向到相应的 CSI 插件(应已安装和配置)。
因此,操作员在过渡到取代树内插件的 CSI 驱动时,无需对现有存储类、PV 或 PVC(指树内插件)进行任何配置更改。
-所支持的操作和功能包括:配备(Provisioning)/删除、挂接(Attach)/解挂(Detach)、
+所支持的操作和特性包括:配备(Provisioning)/删除、挂接(Attach)/解挂(Detach)、
挂载(Mount)/卸载(Unmount)和调整卷大小。
上面的[卷类型](#volume-types)节列出了支持 `CSIMigration` 并已实现相应 CSI
From 5f953799ca1d401c04bea77e5147e4aa676447b6 Mon Sep 17 00:00:00 2001
From: howieyuen
Date: Wed, 25 May 2022 17:55:13 +0800
Subject: [PATCH 129/331] fix: delete redundant quotation
---
.../update-api-object-kubectl-patch.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/zh/docs/tasks/manage-kubernetes-objects/update-api-object-kubectl-patch.md b/content/zh/docs/tasks/manage-kubernetes-objects/update-api-object-kubectl-patch.md
index dd47ec39cf..af9c187e4d 100644
--- a/content/zh/docs/tasks/manage-kubernetes-objects/update-api-object-kubectl-patch.md
+++ b/content/zh/docs/tasks/manage-kubernetes-objects/update-api-object-kubectl-patch.md
@@ -254,7 +254,7 @@ Patch your Deployment:
对 Deployment 执行 patch 操作:
```
-kubectl patch deployment patch-demo --patch-file patch-file-tolerations.yaml"
+kubectl patch deployment patch-demo --patch-file patch-file-tolerations.yaml
```
+
+`apiVersion: rbac.authorization.k8s.io/v1`
+
+`import "k8s.io/api/rbac/v1"`
+
+## Role {#Role}
+
+Role 是一个按命名空间划分的 PolicyRule 逻辑分组,可以被 RoleBinding 作为一个单元引用。
+
+
+
+- **apiVersion**: rbac.authorization.k8s.io/v1
+
+- **kind**: Role
+
+- **metadata** (}}">ObjectMeta)
+
+ 标准的对象元数据。
+
+- **rules** ([]PolicyRule)
+
+ rules 包含了这个 Role 的所有 PolicyRule。
+
+
+ **PolicyRule 包含描述一个策略规则的信息,但不包含该规则适用于哪个主体或适用于哪个命名空间的信息。**
+
+ - **rules.apiGroups** ([]string)
+
+ apiGroups 是包含资源的 apiGroup 的名称。
+ 如果指定了多个 API 组,则允许对任何 API 组中的其中一个枚举资源来请求任何操作。
+
+ - **rules.resources** ([]string)
+
+ resources 是此规则所适用的资源的列表。
+ “*” 表示所有资源。
+
+ - **rules.verbs** ([]string),必需
+
+ verbs 是适用于此规则中所包含的所有 ResourceKinds 的动作。
+ “*” 表示所有动作。
+
+ - **rules.resourceNames** ([]string)
+
+ resourceNames 是此规则所适用的资源名称白名单,可选。
+ 空集合意味着允许所有资源。
+
+ - **rules.nonResourceURLs** ([]string)
+
+ nonResourceURLs 是用户应有权访问的一组部分 URL。
+ 允许使用 “*”,但仅能作为路径中最后一段且必须用于完整的一段,
+ 因为非资源 URL 没有划分命名空间。
+ 此字段仅适用于从 ClusterRoleBinding 引用的 ClusterRole。
+ rules 可以应用到 API 资源(如 “pod” 或 “secret”)或非资源 URL 路径(如 “/api”),
+ 但不能同时应用于两者。
+
+## RoleList {#RoleList}
+
+RoleList 是 Role 的集合。
+
+
+
+- **apiVersion**: rbac.authorization.k8s.io/v1
+
+- **kind**: RoleList
+
+- **metadata** (}}">ListMeta)
+
+ 标准的对象元数据。
+
+- **items** ([]}}">Role),必需
+
+ items 是 Role 的列表。
+
+## 操作 {#Operations}
+
+
+
+### `get` 读取指定的 Role
+
+#### HTTP 请求
+
+GET /apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}
+
+#### 参数
+
+- **name** (**路径参数**): string,必需
+
+ Role 的名称
+
+- **namespace** (**路径参数**): string,必需
+
+ }}">namespace
+
+- **pretty** (**查询参数**): string
+
+ }}">pretty
+
+#### 响应
+
+200 (}}">Role): OK
+
+401: Unauthorized
+
+### `list` 列出或观测类别为 Role 的对象
+
+#### HTTP 请求
+
+GET /apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles
+
+#### 参数
+
+- **namespace** (**路径参数**): string,必需
+
+ }}">namespace
+
+- **allowWatchBookmarks** (**查询参数**): boolean
+
+ }}">allowWatchBookmarks
+
+- **continue** (**查询参数**): string
+
+ }}">continue
+
+- **fieldSelector** (**查询参数**): string
+
+ }}">fieldSelector
+
+- **labelSelector** (**查询参数**): string
+
+ }}">labelSelector
+
+- **limit** (**查询参数**): integer
+
+ }}">limit
+
+- **pretty** (**查询参数**): string
+
+ }}">pretty
+
+- **resourceVersion** (**查询参数**): string
+
+ }}">resourceVersion
+
+- **resourceVersionMatch** (**查询参数**): string
+
+ }}">resourceVersionMatch
+
+- **timeoutSeconds** (**查询参数**): integer
+
+ }}">timeoutSeconds
+
+- **watch** (**查询参数**): boolean
+
+ }}">watch
+
+#### 响应
+
+200 (}}">RoleList): OK
+
+401: Unauthorized
+
+### `list` 列出或观测类别为 Role 的对象
+
+#### HTTP 请求
+
+GET /apis/rbac.authorization.k8s.io/v1/roles
+
+#### 参数
+
+- **allowWatchBookmarks** (**查询参数**): boolean
+
+ }}">allowWatchBookmarks
+
+- **continue** (**查询参数**): string
+
+ }}">continue
+
+- **fieldSelector** (**查询参数**): string
+
+ }}">fieldSelector
+
+- **labelSelector** (**查询参数**): string
+
+ }}">labelSelector
+
+- **limit** (**查询参数**): integer
+
+ }}">limit
+
+- **pretty** (**查询参数**): string
+
+ }}">pretty
+
+- **resourceVersion** (**查询参数**): string
+
+ }}">resourceVersion
+
+- **resourceVersionMatch** (**查询参数**): string
+
+ }}">resourceVersionMatch
+
+- **timeoutSeconds** (**查询参数**): integer
+
+ }}">timeoutSeconds
+
+- **watch** (**查询参数**): boolean
+
+ }}">watch
+
+#### 响应
+
+200 (}}">RoleList): OK
+
+401: Unauthorized
+
+### `create` 创建 Role
+
+#### HTTP 请求
+
+POST /apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles
+
+#### 参数
+
+- **namespace** (**路径参数**): string,必需
+
+ }}">namespace
+
+- **body**: }}">Role,必需
+
+- **dryRun** (**查询参数**): string
+
+ }}">dryRun
+
+- **fieldManager** (**查询参数**): string
+
+ }}">fieldManager
+
+- **fieldValidation** (**查询参数**): string
+
+ }}">fieldValidation
+
+- **pretty** (**查询参数**): string
+
+ }}">pretty
+
+#### 响应
+
+200 (}}">Role): OK
+
+201 (}}">Role): Created
+
+202 (}}">Role): Accepted
+
+401: Unauthorized
+
+### `update` 替换指定的 Role
+
+#### HTTP 请求
+
+PUT /apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}
+
+#### 参数
+
+- **name** (**路径参数**): string,必需
+
+ Role 的名称
+
+- **namespace** (**路径参数**): string,必需
+
+ }}">namespace
+
+- **body**: }}">Role,必需
+
+- **dryRun** (**查询参数**): string
+
+ }}">dryRun
+
+- **fieldManager** (**查询参数**): string
+
+ }}">fieldManager
+
+- **fieldValidation** (**查询参数**): string
+
+ }}">fieldValidation
+
+- **pretty** (**查询参数**): string
+
+ }}">pretty
+
+#### 响应
+
+200 (}}">Role): OK
+
+201 (}}">Role): Created
+
+401: Unauthorized
+
+### `patch` 部分更新指定的 Role
+
+#### HTTP 请求
+
+PATCH /apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}
+
+#### 参数
+
+- **name** (**路径参数**): string,必需
+
+ Role 的名称
+
+- **namespace** (**路径参数**): string,必需
+
+ }}">namespace
+
+- **body**: }}">Patch,必需
+
+- **dryRun** (**查询参数**): string
+
+ }}">dryRun
+
+- **fieldManager** (**查询参数**): string
+
+ }}">fieldManager
+
+- **fieldValidation** (**查询参数**): string
+
+ }}">fieldValidation
+
+- **force** (**查询参数**): boolean
+
+ }}">force
+
+- **pretty** (**查询参数**): string
+
+ }}">pretty
+
+#### 响应
+
+200 (}}">Role): OK
+
+201 (}}">Role): Created
+
+401: Unauthorized
+
+### `delete` 删除 Role
+
+#### HTTP 请求
+
+DELETE /apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles/{name}
+
+#### 参数
+
+- **name** (**路径参数**): string,必需
+
+ Role 的名称
+
+- **namespace** (**路径参数**): string,必需
+
+ }}">namespace
+
+- **body**: }}">DeleteOptions
+
+- **dryRun** (**查询参数**): string
+
+ }}">dryRun
+
+- **gracePeriodSeconds** (**查询参数**): integer
+
+ }}">gracePeriodSeconds
+
+- **pretty** (**查询参数**): string
+
+ }}">pretty
+
+- **propagationPolicy** (**查询参数**): string
+
+ }}">propagationPolicy
+
+#### 响应
+
+200 (}}">Status): OK
+
+202 (}}">Status): Accepted
+
+401: Unauthorized
+
+### `deletecollection` 删除 Role 的集合
+
+#### HTTP 请求
+
+DELETE /apis/rbac.authorization.k8s.io/v1/namespaces/{namespace}/roles
+
+#### 参数
+
+- **namespace** (**路径参数**): string,必需
+
+ }}">namespace
+
+- **body**: }}">DeleteOptions
+
+- **continue** (**查询参数**): string
+
+ }}">continue
+
+- **dryRun** (**查询参数**): string
+
+ }}">dryRun
+
+- **fieldSelector** (**查询参数**): string
+
+ }}">fieldSelector
+
+- **gracePeriodSeconds** (**查询参数**): integer
+
+ }}">gracePeriodSeconds
+
+- **labelSelector** (**查询参数**): string
+
+ }}">labelSelector
+
+- **limit** (**查询参数**): integer
+
+ }}">limit
+
+- **pretty** (**查询参数**): string
+
+ }}">pretty
+
+- **propagationPolicy** (**查询参数**): string
+
+ }}">propagationPolicy
+
+- **resourceVersion** (**查询参数**): string
+
+ }}">resourceVersion
+
+- **resourceVersionMatch** (**查询参数**): string
+
+ }}">resourceVersionMatch
+
+- **timeoutSeconds** (**查询参数**): integer
+
+ }}">timeoutSeconds
+
+#### 响应
+
+200 (}}">Status): OK
+
+401: Unauthorized
From cca0aca8550be1a6d24efaf64f6e731028665111 Mon Sep 17 00:00:00 2001
From: Sean Wei
Date: Sat, 21 May 2022 02:17:51 +0800
Subject: [PATCH 131/331] Fix Markdown link
---
content/en/docs/concepts/configuration/secret.md | 6 +++---
content/en/docs/contribute/participate/pr-wranglers.md | 2 +-
.../docs/tasks/administer-cluster/configure-upgrade-etcd.md | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/content/en/docs/concepts/configuration/secret.md b/content/en/docs/concepts/configuration/secret.md
index d9611439a4..3bdfb16a0c 100644
--- a/content/en/docs/concepts/configuration/secret.md
+++ b/content/en/docs/concepts/configuration/secret.md
@@ -982,7 +982,7 @@ kubectl create secret docker-registry secret-tiger-docker \
```
That command creates a Secret of type `kubernetes.io/dockerconfigjson`.
-If you dump the `.data.dockercfgjson` field from that new Secret and then
+If you dump the `.data.dockerconfigjson` field from that new Secret and then
decode it from base64:
```shell
@@ -1291,7 +1291,7 @@ on that node.
- When deploying applications that interact with the Secret API, you should
limit access using
[authorization policies](/docs/reference/access-authn-authz/authorization/) such as
- [RBAC]( /docs/reference/access-authn-authz/rbac/).
+ [RBAC](/docs/reference/access-authn-authz/rbac/).
- In the Kubernetes API, `watch` and `list` requests for Secrets within a namespace
are extremely powerful capabilities. Avoid granting this access where feasible, since
listing Secrets allows the clients to inspect the values of every Secret in that
@@ -1310,7 +1310,7 @@ have access to run a Pod that then exposes the Secret.
- When deploying applications that interact with the Secret API, you should
limit access using
[authorization policies](/docs/reference/access-authn-authz/authorization/) such as
- [RBAC]( /docs/reference/access-authn-authz/rbac/).
+ [RBAC](/docs/reference/access-authn-authz/rbac/).
- In the API server, objects (including Secrets) are persisted into
{{< glossary_tooltip term_id="etcd" >}}; therefore:
- only allow cluster admistrators to access etcd (this includes read-only access);
diff --git a/content/en/docs/contribute/participate/pr-wranglers.md b/content/en/docs/contribute/participate/pr-wranglers.md
index 865af35805..42c1d2b32b 100644
--- a/content/en/docs/contribute/participate/pr-wranglers.md
+++ b/content/en/docs/contribute/participate/pr-wranglers.md
@@ -100,4 +100,4 @@ In late 2021, SIG Docs introduced the PR Wrangler Shadow Program. The program wa
- Others can reach out on the [#sig-docs Slack channel](https://kubernetes.slack.com/messages/sig-docs) for requesting to shadow an assigned PR Wrangler for a specific week. Feel free to reach out to Brad Topol (`@bradtopol`) or one of the [SIG Docs co-chairs/leads](https://github.com/kubernetes/community/tree/master/sig-docs#leadership).
-- Once you've signed up to shadow a PR Wrangler, introduce yourself to the PR Wrangler on the [Kubernetes Slack](slack.k8s.io).
\ No newline at end of file
+- Once you've signed up to shadow a PR Wrangler, introduce yourself to the PR Wrangler on the [Kubernetes Slack](https://slack.k8s.io).
diff --git a/content/en/docs/tasks/administer-cluster/configure-upgrade-etcd.md b/content/en/docs/tasks/administer-cluster/configure-upgrade-etcd.md
index bf5ddd8f5f..be77074dc1 100644
--- a/content/en/docs/tasks/administer-cluster/configure-upgrade-etcd.md
+++ b/content/en/docs/tasks/administer-cluster/configure-upgrade-etcd.md
@@ -150,7 +150,7 @@ access to clients with the certificate `k8sclient.cert`.
Once etcd is configured correctly, only clients with valid certificates can
access it. To give Kubernetes API servers the access, configure them with the
-flags `--etcd-certfile=k8sclient.cert`,`--etcd-keyfile=k8sclient.key` and
+flags `--etcd-certfile=k8sclient.cert`, `--etcd-keyfile=k8sclient.key` and
`--etcd-cafile=ca.cert`.
{{< note >}}
@@ -319,7 +319,7 @@ employed to recover the data of a failed cluster.
Before starting the restore operation, a snapshot file must be present. It can
either be a snapshot file from a previous backup operation, or from a remaining
-[data directory]( https://etcd.io/docs/current/op-guide/configuration/#--data-dir).
+[data directory](https://etcd.io/docs/current/op-guide/configuration/#--data-dir).
Here is an example:
```shell
From 2c154e13f5b05837e0ca3352b7cba806201e82b7 Mon Sep 17 00:00:00 2001
From: Tom Kivlin <52716470+tomkivlin@users.noreply.github.com>
Date: Wed, 25 May 2022 15:15:38 +0100
Subject: [PATCH 132/331] remove duplicate 'the'
---
.../extend-kubernetes/compute-storage-net/network-plugins.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/en/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins.md b/content/en/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins.md
index 52b0bc3e26..647111b375 100644
--- a/content/en/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins.md
+++ b/content/en/docs/concepts/extend-kubernetes/compute-storage-net/network-plugins.md
@@ -54,7 +54,7 @@ By default, if no kubelet network plugin is specified, the `noop` plugin is used
### Loopback CNI
In addition to the CNI plugin installed on the nodes for implementing the Kubernetes network model, Kubernetes also requires the container runtimes to provide a loopback interface `lo`, which is used for each sandbox (pod sandboxes, vm sandboxes, ...).
-Implementing the loopback interface can be accomplished by re-using the [the CNI loopback plugin.](https://github.com/containernetworking/plugins/blob/master/plugins/main/loopback/loopback.go) or by developing your own code to achieve this (see [this example from CRI-O](https://github.com/cri-o/ocicni/blob/release-1.24/pkg/ocicni/util_linux.go#L91)).
+Implementing the loopback interface can be accomplished by re-using the [CNI loopback plugin.](https://github.com/containernetworking/plugins/blob/master/plugins/main/loopback/loopback.go) or by developing your own code to achieve this (see [this example from CRI-O](https://github.com/cri-o/ocicni/blob/release-1.24/pkg/ocicni/util_linux.go#L91)).
### Support hostPort
From 694abb29622bed76830fe7b72df9a940385c5103 Mon Sep 17 00:00:00 2001
From: kadtendulkar
Date: Wed, 25 May 2022 21:28:36 +0530
Subject: [PATCH 133/331] update content/en/releases/version-skew-policy.md
---
content/en/releases/version-skew-policy.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/content/en/releases/version-skew-policy.md b/content/en/releases/version-skew-policy.md
index 87f6cf2c62..f59ab71ad8 100644
--- a/content/en/releases/version-skew-policy.md
+++ b/content/en/releases/version-skew-policy.md
@@ -26,7 +26,7 @@ For more information, see [Kubernetes Release Versioning](https://github.com/kub
The Kubernetes project maintains release branches for the most recent three minor releases ({{< skew latestVersion >}}, {{< skew prevMinorVersion >}}, {{< skew oldestMinorVersion >}}). Kubernetes 1.19 and newer receive approximately 1 year of patch support. Kubernetes 1.18 and older received approximately 9 months of patch support.
Applicable fixes, including security fixes, may be backported to those three release branches, depending on severity and feasibility.
-Patch releases are cut from those branches at a [regular cadence](https://git.k8s.io/sig-release/releases/patch-releases.md#cadence), plus additional urgent releases, when required.
+Patch releases are cut from those branches at a [regular cadence](https://kubernetes.io/releases/patch-releases/#cadence), plus additional urgent releases, when required.
The [Release Managers](/releases/release-managers/) group owns this decision.
From 9c71a06df47872e142ffcc44a3bf62eef3390dd0 Mon Sep 17 00:00:00 2001
From: "wei.wang"
Date: Thu, 26 May 2022 02:26:45 +0800
Subject: [PATCH 134/331] [zh]Update
content/zh/docs/reference/config-api/kubeadm-config.v1beta2.md
---
.../config-api/kubeadm-config.v1beta2.md | 34 +++++++++----------
.../config-api/kubeadm-config.v1beta3.md | 20 ++++++-----
2 files changed, 28 insertions(+), 26 deletions(-)
diff --git a/content/zh/docs/reference/config-api/kubeadm-config.v1beta2.md b/content/zh/docs/reference/config-api/kubeadm-config.v1beta2.md
index f34da9f473..bc37e362a7 100644
--- a/content/zh/docs/reference/config-api/kubeadm-config.v1beta2.md
+++ b/content/zh/docs/reference/config-api/kubeadm-config.v1beta2.md
@@ -292,7 +292,7 @@ https://godoc.org/k8s.io/kubelet/config/v1beta1#KubeletConfiguration。
criSocket:"/var/run/dockershim.sock"taints:- key:"kubeadmNode"
-value:"master"
+value:"someValue"effect:"NoSchedule"kubeletExtraArgs:v:4
@@ -1274,9 +1274,10 @@ cluster information.
tlsBootstrapToken 是 TLS 启动引导过程中使用的令牌。
如果设置了 bootstrapToken,则此字段默认值为 .bootstrapToken.token,
@@ -1783,29 +1784,28 @@ Defaults to the hostname of the node if not provided.
criSocket 用来读取容器运行时的信息。
-此信息会被以注解的方式添加到 Node API 对象至上,用于后续用途。
-
+If this field is unset, i.e. nil, in the kubeadm init process it will be defaulted with
+a control-plane taint for control-plane nodes. If you don't want to taint your control-plane
+node, set this field to an empty list, i.e. taints: [], in the YAML file. This field is
+solely used for Node registration.
+-->
kubeletExtraArgs[必需]
diff --git a/content/zh/docs/reference/config-api/kubeadm-config.v1beta3.md b/content/zh/docs/reference/config-api/kubeadm-config.v1beta3.md
index 2a53c835db..ef491a424e 100644
--- a/content/zh/docs/reference/config-api/kubeadm-config.v1beta3.md
+++ b/content/zh/docs/reference/config-api/kubeadm-config.v1beta3.md
@@ -313,7 +313,7 @@ https://godoc.org/k8s.io/kubelet/config/v1beta1#KubeletConfiguration。
criSocket:"/var/run/dockershim.sock"taints:- key:"kubeadmNode"
-value:"master"
+value:"someValue"effect:"NoSchedule"kubeletExtraArgs:v:4
@@ -1655,15 +1655,17 @@ This information will be annotated to the Node API object, for later re-use[]core/v1.Taint