@@ -13,7 +13,7 @@ min-kubernetes-server-version: 1.27
13
13
14
14
<!-- overview -->
15
15
16
- {{< feature-state state="alpha" for_k8s_version="v1.27 " >}}
16
+ {{< feature-state feature_gate_name="InPlacePodVerticalScaling " >}}
17
17
18
18
<!--
19
19
This page assumes that you are familiar with [Quality of Service](/docs/tasks/configure-pod-container/quality-service-pod/)
@@ -31,6 +31,17 @@ resource usage based on the `limits` specified in the pod's containers.
31
31
Kubernetes 节点会基于 Pod 的 ` requests ` 为 Pod 分配资源,
32
32
并基于 Pod 的容器中指定的 ` limits ` 限制 Pod 的资源使用。
33
33
34
+ <!--
35
+ Changing the resource allocation for a running Pod requires the
36
+ `InPlacePodVerticalScaling` [feature gate](/docs/reference/command-line-tools-reference/feature-gates/)
37
+ to be enabled. The alternative is to delete the Pod and let the
38
+ [workload controller](/docs/concepts/workloads/controllers/) make a replacement Pod
39
+ that has a different resource requirement.
40
+ -->
41
+ 要为正在运行的 Pod 更改资源分配量,需要启用 ` InPlacePodVerticalScaling `
42
+ [ 特性门控] ( /zh-cn/docs/reference/command-line-tools-reference/feature-gates/ ) 。
43
+ 并让[ 工作负载控制器] ( /zh-cn/docs/concepts/workloads/controllers/ ) 创建一个具有不同资源需求的新 Pod。
44
+
34
45
<!--
35
46
For in-place resize of pod resources:
36
47
- Container's resource `requests` and `limits` are _mutable_ for CPU
@@ -73,6 +84,13 @@ For in-place resize of pod resources:
73
84
74
85
{{< include "task-tutorial-prereqs.md" >}} {{< version-check >}}
75
86
87
+ <!--
88
+ The `InPlacePodVerticalScaling` [feature gate](/docs/reference/command-line-tools-reference/feature-gates/) must be enabled
89
+ for your control plane and for all nodes in your cluster.
90
+ -->
91
+ 你必须在控制平面和集群中的所有节点上启用 ` InPlacePodVerticalScaling `
92
+ [ 特性门控] ( /zh-cn/docs/reference/command-line-tools-reference/feature-gates/ ) 。
93
+
76
94
<!--
77
95
## Container Resize Policies
78
96
@@ -241,13 +259,13 @@ spec:
241
259
<!--
242
260
# # Updating the pod's resources
243
261
244
- Let's say the CPU requirements have increased, and 0.8 CPU is now desired. This
245
- is typically determined, and may be programmatically applied, by an entity such as
262
+ Let's say the CPU requirements have increased, and 0.8 CPU is now desired. This may
263
+ be specified manually, or determined and programmatically applied by an entity such as
246
264
[VerticalPodAutoscaler](https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler#readme) (VPA).
247
265
-->
248
266
# # 更新 Pod 的资源 {#updating-pod-resources}
249
267
250
- 假设要求的 CPU 需求已上升,现在需要 0.8 CPU。这通常由
268
+ 假设要求的 CPU 需求已上升,现在需要 0.8 CPU。这可以手动指定,或由如
251
269
[VerticalPodAutoscaler](https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler#readme) (VPA)
252
270
这样的实体确定并可能以编程方式应用。
253
271
0 commit comments