From 6ae7201d74b70b95e9fb16bb16cb9bc2ada111a9 Mon Sep 17 00:00:00 2001 From: Davanum Srinivas Date: Tue, 24 Oct 2017 17:33:41 -0400 Subject: [PATCH] Deprecate using cloud provider to set host address feature Long term plan is to remove all uses of cloud provider from kube api server. As part of that, we need to remove the dependency on figuring out the host address of the node running the kube api server using the cloud provider. In this review, we log a warning that this feature that is usually used for example with swagger generation will go away in the future. --- pkg/kubeapiserver/options/cloudprovider.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkg/kubeapiserver/options/cloudprovider.go b/pkg/kubeapiserver/options/cloudprovider.go index f1e59976242..310acb592ce 100644 --- a/pkg/kubeapiserver/options/cloudprovider.go +++ b/pkg/kubeapiserver/options/cloudprovider.go @@ -81,6 +81,8 @@ func (s *CloudProviderOptions) DefaultExternalHost(genericoptions *genericoption for _, addr := range addrs { if addr.Type == v1.NodeExternalIP { genericoptions.ExternalHost = addr.Address + glog.Warning("[Deprecated] Getting host address using cloud provider is " + + "now deprecated. Please use --external-hostname explicitly") } } }