You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
IPBlock defines policy on a particular IPBlock. If this field is set then neither of the other fields can be.
137
137
138
138
<a name="IPBlock"></a>
139
-
*IPBlock describes a particular CIDR (Ex. "192.168.1.1/24","2001:db9::/64") that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The except entry describes CIDRs that should not be included within this rule.*
139
+
*IPBlock describes a particular CIDR (Ex. "192.168.1.0/24","2001:db8::/64") that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The except entry describes CIDRs that should not be included within this rule.*
CIDR is a string representing the IP Block Valid examples are "192.168.1.1/24" or "2001:db9::/64"
154
+
CIDR is a string representing the IP Block Valid examples are "192.168.1.0/24" or "2001:db8::/64"
155
155
156
156
- **ingress.from.ipBlock.except** ([]string)
157
157
158
-
Except is a slice of CIDRs that should not be included within an IP Block Valid examples are "192.168.1.1/24" or "2001:db9::/64" Except values will be rejected if they are outside the CIDR range
158
+
Except is a slice of CIDRs that should not be included within an IP Block Valid examples are "192.168.1.0/24" or "2001:db8::/64" Except values will be rejected if they are outside the CIDR range
159
159
-->
160
160
161
161
-**ingress.from.ipBlock.cidr** (string),必需
162
162
163
-
CIDR 是指定 IP 组块的字符串,例如 `"192.168.1.1/24"` 或 `"2001:db9::/64"`。
163
+
CIDR 是指定 IP 组块的字符串,例如 `"192.168.1.0/24"` 或 `"2001:db8::/64"`。
164
164
165
165
-**ingress.from.ipBlock.except** ([]string)
166
166
167
167
except 是一个由 CIDR 范围组成的列表,其中指定的 CIDR 都应排除在此 IP 区块范围之外。
IPBlock defines policy on a particular IPBlock. If this field is set then neither of the other fields can be.
303
303
304
304
<a name="IPBlock"></a>
305
-
*IPBlock describes a particular CIDR (Ex. "192.168.1.1/24","2001:db9::/64") that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The except entry describes CIDRs that should not be included within this rule.*
305
+
*IPBlock describes a particular CIDR (Ex. "192.168.1.0/24","2001:db8::/64") that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The except entry describes CIDRs that should not be included within this rule.*
与 NetworkPolicySpec 的 podSelector 匹配的 Pod 将被允许连接到这个 IP 范围,作为其出口流量目的地。
315
315
except 字段则设置了不被此规则影响的 CIDR 范围。**
316
316
317
317
<!--
318
318
- **egress.to.ipBlock.cidr** (string), required
319
319
320
-
CIDR is a string representing the IP Block Valid examples are "192.168.1.1/24" or "2001:db9::/64"
320
+
CIDR is a string representing the IP Block Valid examples are "192.168.1.0/24" or "2001:db8::/64"
321
321
322
322
- **egress.to.ipBlock.except** ([]string)
323
323
324
-
Except is a slice of CIDRs that should not be included within an IP Block Valid examples are "192.168.1.1/24" or "2001:db9::/64" Except values will be rejected if they are outside the CIDR range
324
+
Except is a slice of CIDRs that should not be included within an IP Block Valid examples are "192.168.1.0/24" or "2001:db8::/64" Except values will be rejected if they are outside the CIDR range
325
325
-->
326
326
327
327
-**egress.to.ipBlock.cidr** (string),必需
328
328
329
-
CIDR 是用来表达 IP 组块的字符串,例如 `"192.168.1.1/24"` 或 `"2001:db9::/64"`。
329
+
CIDR 是用来表达 IP 组块的字符串,例如 `"192.168.1.0/24"` 或 `"2001:db8::/64"`。
Copy file name to clipboardExpand all lines: content/zh-cn/docs/reference/kubernetes-api/service-resources/endpoint-slice-v1.md
+2-4Lines changed: 2 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -119,24 +119,22 @@ EndpointSlice 是实现某 Service 的端点的子集。一个 Service 可以有
119
119
-**endpoints.conditions.serving** (boolean)
120
120
121
121
<!--
122
-
Serving is identical to ready except that it is set regardless of the terminating state of endpoints. This condition should be set to true for a ready endpoint that is terminating. If nil, consumers should defer to the ready condition. This field can be enabled with the EndpointSliceTerminatingCondition feature gate.
122
+
Serving is identical to ready except that it is set regardless of the terminating state of endpoints. This condition should be set to true for a ready endpoint that is terminating. If nil, consumers should defer to the ready condition.
123
123
-->
124
124
125
125
serving 和 ready 非常相似。唯一的不同在于,
126
126
即便某端点的状态为 Terminating 也可以设置 serving。
127
127
对于处在终止过程中的就绪端点,此状况应被设置为 “true”。
128
128
如果设置为 nil,则消费者应该以 ready 值为准。
129
-
可以在 EndpointSliceTerminatingCondition 特性开关中启用此字段。
130
129
131
130
-**endpoints.conditions.terminating** (boolean)
132
131
133
132
<!--
134
-
terminating indicates that this endpoint is terminating. A nil value indicates an unknown state. Consumers should interpret this unknown state to mean that the endpoint is not terminating. This field can be enabled with the EndpointSliceTerminatingCondition feature gate.
133
+
terminating indicates that this endpoint is terminating. A nil value indicates an unknown state. Consumers should interpret this unknown state to mean that the endpoint is not terminating.
Copy file name to clipboardExpand all lines: content/zh-cn/docs/reference/kubernetes-api/service-resources/service-v1.md
+12-10Lines changed: 12 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -363,33 +363,35 @@ ServiceSpec 描述用户在服务上创建的属性。
363
363
-**externalTrafficPolicy** (string)
364
364
365
365
<!--
366
-
externalTrafficPolicy denotes if this Service desires to route external traffic to node-local or cluster-wide endpoints. "Local" preserves the client source IP and avoids a second hop for LoadBalancer and Nodeport type services, but risks potentially imbalanced traffic spreading. "Cluster" obscures the client source IP and may cause a second hop to another node, but should have good overall load-spreading.
366
+
externalTrafficPolicy describes how nodes distribute service traffic they receive on one of the Service's "externally-facing" addresses (NodePorts, ExternalIPs, and LoadBalancer IPs). If set to "Local", the proxy will configure the service in a way that assumes that external load balancers will take care of balancing the service traffic between nodes, and so each node will deliver traffic only to the node-local endpoints of the service, without masquerading the client source IP. (Traffic mistakenly sent to a node with no endpoints will be dropped.) The default value, "Cluster", uses the standard behavior of routing to all endpoints evenly (possibly modified by topology and other features). Note that traffic sent to an External IP or LoadBalancer IP from within the cluster will always get "Cluster" semantics, but clients sending to a NodePort from within the cluster may need to take traffic policy into account when picking a node.
367
367
-->
368
-
externalTrafficPolicy 表示此 Service 是否希望将外部流量路由到节点本地或集群范围的 Endpoint。
369
-
字段值 “Local” 保留客户端 IP 并可避免 LoadBalancer 和 Nodeport 类型 Service 的第二跳,但存在潜在流量传播不平衡的风险。
请注意,从集群内部发送到 External IP 或 LoadBalancer IP 的流量始终具有“Cluster”语义,但是从集群内部发送到 NodePort 的客户端需要在选择节点时考虑流量路由策略。
371
373
372
374
-**internalTrafficPolicy** (string)
373
375
374
376
<!--
375
-
InternalTrafficPolicy specifies if the cluster internal traffic should be routed to all endpoints or node-local endpoints only. "Cluster" routes internal traffic to a Service to all endpoints. "Local" routes traffic to node-local endpoints only, traffic is dropped if no node-local endpoints are ready. The default value is "Cluster".
377
+
InternalTrafficPolicy describes how nodes distribute service traffic they receive on the ClusterIP. If set to "Local", the proxy will assume that pods only want to talk to endpoints of the service on the same node as the pod, dropping the traffic if there are no local endpoints. The default value, "Cluster", uses the standard behavior of routing to all endpoints evenly (possibly modified by topology and other features).
healthCheckNodePort specifies the healthcheck nodePort for the service. This only applies when type is set to LoadBalancer and externalTrafficPolicy is set to Local. If a value is specified, is in-range, and is not in use, it will be used. If not specified, a value will be automatically allocated. External systems (e.g. load-balancers) can use this port to determine if a given node holds endpoints for this service or not. If this field is specified when creating a Service which does not need it, creation will fail. This field will be wiped when updating a Service to no longer need it (e.g. changing type).
386
+
healthCheckNodePort specifies the healthcheck nodePort for the service. This only applies when type is set to LoadBalancer and externalTrafficPolicy is set to Local. If a value is specified, is in-range, and is not in use, it will be used. If not specified, a value will be automatically allocated. External systems (e.g. load-balancers) can use this port to determine if a given node holds endpoints for this service or not. If this field is specified when creating a Service which does not need it, creation will fail. This field will be wiped when updating a Service to no longer need it (e.g. changing type). This field cannot be updated once set.
386
387
-->
387
388
healthCheckNodePort 指定 Service 的健康检查节点端口。
388
389
仅适用于 type 为 LoadBalancer 且 externalTrafficPolicy 设置为 Local 的情况。
0 commit comments