Commit ce76bab3 authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #46960 from lukaszo/fedint

Automatic merge from submit-queue Add NodeInternalIP as a fallback to federation api-server nodeport service Previously NodeLegacyHostIP was used as a fallback (see #41243) but in 1.7 it was removed (#44830) Now clusters where nodes have not set ExternalIP can not be used by kubefed to setup federation. cc @shashidharatd ```release-note kubefed will now configure NodeInternalIP as the federation API server endpoint when NodeExternalIP is unavailable for federation API servers exposed as NodePort services ```
parents 1a857ca5 6e6c903a
...@@ -496,6 +496,7 @@ func createService(cmdOut io.Writer, clientset client.Interface, namespace, svcN ...@@ -496,6 +496,7 @@ func createService(cmdOut io.Writer, clientset client.Interface, namespace, svcN
func getClusterNodeIPs(clientset client.Interface) ([]string, error) { func getClusterNodeIPs(clientset client.Interface) ([]string, error) {
preferredAddressTypes := []api.NodeAddressType{ preferredAddressTypes := []api.NodeAddressType{
api.NodeExternalIP, api.NodeExternalIP,
api.NodeInternalIP,
} }
nodeList, err := clientset.Core().Nodes().List(metav1.ListOptions{}) nodeList, err := clientset.Core().Nodes().List(metav1.ListOptions{})
if err != nil { if err != nil {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment