@@ -3985,13 +3985,21 @@ type ServiceSpec struct {
3985
3985
// +optional
3986
3986
SessionAffinityConfig * SessionAffinityConfig `json:"sessionAffinityConfig,omitempty" protobuf:"bytes,14,opt,name=sessionAffinityConfig"`
3987
3987
3988
- // ipFamily specifies whether this Service has a preference for a particular IP family (e.g. IPv4 vs.
3989
- // IPv6). If a specific IP family is requested, the clusterIP field will be allocated from that family, if it is
3990
- // available in the cluster. If no IP family is requested, the cluster's primary IP family will be used.
3991
- // Other IP fields (loadBalancerIP, loadBalancerSourceRanges, externalIPs) and controllers which
3992
- // allocate external load-balancers should use the same IP family. Endpoints for this Service will be of
3993
- // this family. This field is immutable after creation. Assigning a ServiceIPFamily not available in the
3994
- // cluster (e.g. IPv6 in IPv4 only cluster) is an error condition and will fail during clusterIP assignment.
3988
+ // ipFamily specifies whether this Service has a preference for a particular IP family (e.g.
3989
+ // IPv4 vs. IPv6) when the IPv6DualStack feature gate is enabled. In a dual-stack cluster,
3990
+ // you can specify ipFamily when creating a ClusterIP Service to determine whether the
3991
+ // controller will allocate an IPv4 or IPv6 IP for it, and you can specify ipFamily when
3992
+ // creating a headless Service to determine whether it will have IPv4 or IPv6 Endpoints. In
3993
+ // either case, if you do not specify an ipFamily explicitly, it will default to the
3994
+ // cluster's primary IP family.
3995
+ // This field is part of an alpha feature, and you should not make any assumptions about its
3996
+ // semantics other than those described above. In particular, you should not assume that it
3997
+ // can (or cannot) be changed after creation time; that it can only have the values "IPv4"
3998
+ // and "IPv6"; or that its current value on a given Service correctly reflects the current
3999
+ // state of that Service. (For ClusterIP Services, look at clusterIP to see if the Service
4000
+ // is IPv4 or IPv6. For headless Services, look at the endpoints, which may be dual-stack in
4001
+ // the future. For ExternalName Services, ipFamily has no meaning, but it may be set to an
4002
+ // irrelevant value anyway.)
3995
4003
// +optional
3996
4004
IPFamily * IPFamily `json:"ipFamily,omitempty" protobuf:"bytes,15,opt,name=ipFamily,Configcasttype=IPFamily"`
3997
4005
0 commit comments