Merge pull request #36095 from caesarxuchao/deprecate-LegacyHostIP
Automatic merge from submit-queue [RFC] Prepare for deprecating NodeLegacyHostIP Ref https://github.com/kubernetes/kubernetes/issues/9267#issuecomment-257994766 *What this PR does* - Add comments saying "LegacyHostIP" will be deprecated in 1.7; - Add v1.NodeLegacyHostIP to be consistent with the internal API (useful for client-go migration #35159) - Let cloudproviders who used to only set LegacyHostIP set the IP as both InternalIP and ExternalIP - Master used to ssh tunnel to node's ExternalIP or LegacyHostIP to do [healthz check](https://github.com/kubernetes/kubernetes/blame/master/pkg/master/master.go#L328-L332). OTOH, if on-prem, kubelet only [sets](https://github.com/kubernetes/kubernetes/blob/master/pkg/kubelet/kubelet_node_status.go#L430-L431) LegacyHostIP or InternalIP. In order to deprecate LegacyHostIP in 1.7, I let healthz check to use InternalIP if ExternalIP is not available. (The healthz check is the only consumer of LegacyHostIP in k8s.) @liggitt @justinsb @bgrant0607 ```release-note LegacyHostIP will be deprecated in 1.7. ```
This commit is contained in:
@@ -2598,6 +2598,7 @@ type NodeAddressType string
|
||||
// These are valid address types of node. NodeLegacyHostIP is used to transit
|
||||
// from out-dated HostIP field to NodeAddress.
|
||||
const (
|
||||
// Deprecated: NodeLegacyHostIP will be removed in 1.7.
|
||||
NodeLegacyHostIP NodeAddressType = "LegacyHostIP"
|
||||
NodeHostName NodeAddressType = "Hostname"
|
||||
NodeExternalIP NodeAddressType = "ExternalIP"
|
||||
|
Reference in New Issue
Block a user