Skip to content

Commit 1ac62a1

Browse files
authored
Merge pull request #39850 from xuzhenglun/dev-1.27
add doc for ServiceNodePortStaticSubrange
2 parents fef3fbf + 6887d39 commit 1ac62a1

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

content/en/docs/concepts/services-networking/service.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -586,6 +586,20 @@ spec:
586586
nodePort: 30007
587587
```
588588
589+
#### Reserve Nodeport Ranges to avoid collisions when port assigning
590+
591+
{{< feature-state for_k8s_version="v1.27" state="alpha" >}}
592+
593+
The policy for assigning ports to NodePort services applies to both the auto-assignment and
594+
the manual assignment scenarios. When a user wants to create a NodePort service that
595+
uses a specific port, the target port may conflict with another port that has already been assigned.
596+
In this case, you can enable the feature gate `ServiceNodePortStaticSubrange`, which allows you
597+
to use a different port allocation strategy for NodePort Services. The port range for NodePort services
598+
is divided into two bands. Dynamic port assignment uses the upper band by default, and it may use
599+
the lower band once the upper band has been exhausted. Users can then allocate from the lower band
600+
with a lower risk of port collision.
601+
602+
589603
#### Custom IP address configuration for `type: NodePort` Services {#service-nodeport-custom-listen-address}
590604

591605
You can set up nodes in your cluster to use a particular IP address for serving node port

content/en/docs/reference/command-line-tools-reference/feature-gates.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ For a reference to old feature gates that are removed, please refer to
186186
| `SeccompDefault` | `true` | Beta | 1.25 | |
187187
| `ServerSideFieldValidation` | `false` | Alpha | 1.23 | 1.24 |
188188
| `ServerSideFieldValidation` | `true` | Beta | 1.25 | |
189+
| `ServiceNodePortStaticSubrange` | `false` | Alpha | 1.27 | |
189190
| `SizeMemoryBackedVolumes` | `false` | Alpha | 1.20 | 1.21 |
190191
| `SizeMemoryBackedVolumes` | `true` | Beta | 1.22 | |
191192
| `StatefulSetAutoDeletePVC` | `false` | Alpha | 1.22 | |

0 commit comments

Comments
 (0)