diff --git a/pkg/agent/config/config.go b/pkg/agent/config/config.go index 2ab0299328..a1082c6e93 100644 --- a/pkg/agent/config/config.go +++ b/pkg/agent/config/config.go @@ -27,7 +27,7 @@ import ( "github.com/sirupsen/logrus" "k8s.io/apimachinery/pkg/util/json" "k8s.io/apimachinery/pkg/util/net" - "k8s.io/kubernetes/pkg/kubelet/apis/deviceplugin/v1beta1" + "k8s.io/kubelet/pkg/apis/deviceplugin/v1beta1" ) func Get(ctx context.Context, agent cmds.Agent) *config.Node { diff --git a/pkg/cli/server/server.go b/pkg/cli/server/server.go index dbf27eb298..b716152b3a 100644 --- a/pkg/cli/server/server.go +++ b/pkg/cli/server/server.go @@ -124,7 +124,7 @@ func run(app *cli.Context, cfg *cmds.Server) error { return errors.Wrapf(err, "Invalid CIDR %s: %v", cfg.ServiceCIDR, err) } - _, apiServerServiceIP, err := master.DefaultServiceIPRange(*serverConfig.ControlConfig.ServiceIPRange) + _, apiServerServiceIP, err := master.ServiceIPRange(*serverConfig.ControlConfig.ServiceIPRange) if err != nil { return err } diff --git a/pkg/daemons/agent/agent.go b/pkg/daemons/agent/agent.go index 72b8d23a68..cb9f9f05ee 100644 --- a/pkg/daemons/agent/agent.go +++ b/pkg/daemons/agent/agent.go @@ -18,8 +18,8 @@ import ( kubelet "k8s.io/kubernetes/cmd/kubelet/app" "k8s.io/kubernetes/pkg/kubeapiserver/authorizer/modes" - _ "k8s.io/kubernetes/pkg/client/metrics/prometheus" // for client metric registration - _ "k8s.io/kubernetes/pkg/version/prometheus" // for version metric registration + _ "k8s.io/component-base/metrics/prometheus/restclient" // for client metric registration + _ "k8s.io/component-base/metrics/prometheus/version" // for version metric registration ) func Agent(config *config.Agent) error { diff --git a/pkg/daemons/control/server.go b/pkg/daemons/control/server.go index 62d3b1fe94..f27234cb1a 100644 --- a/pkg/daemons/control/server.go +++ b/pkg/daemons/control/server.go @@ -32,12 +32,12 @@ import ( "k8s.io/apiserver/pkg/authentication/authenticator" "k8s.io/client-go/kubernetes" "k8s.io/client-go/tools/clientcmd" + _ "k8s.io/component-base/metrics/prometheus/restclient" // for client metric registration ccmapp "k8s.io/kubernetes/cmd/cloud-controller-manager/app" app2 "k8s.io/kubernetes/cmd/controller-manager/app" "k8s.io/kubernetes/cmd/kube-apiserver/app" cmapp "k8s.io/kubernetes/cmd/kube-controller-manager/app" sapp "k8s.io/kubernetes/cmd/kube-scheduler/app" - _ "k8s.io/kubernetes/pkg/client/metrics/prometheus" // for client metric registration "k8s.io/kubernetes/pkg/kubeapiserver/authorizer/modes" "k8s.io/kubernetes/pkg/master" "k8s.io/kubernetes/pkg/proxy/util" @@ -568,7 +568,7 @@ func genServerCerts(config *config.Control, runtime *config.ControlRuntime) erro return err } - _, apiServerServiceIP, err := master.DefaultServiceIPRange(*config.ServiceIPRange) + _, apiServerServiceIP, err := master.ServiceIPRange(*config.ServiceIPRange) if err != nil { return err } diff --git a/pkg/server/context.go b/pkg/server/context.go index eec39b39e3..a9f1bd575f 100644 --- a/pkg/server/context.go +++ b/pkg/server/context.go @@ -51,7 +51,7 @@ func newContext(ctx context.Context, cfg string) (*Context, error) { Apps: apps.NewFactoryFromConfigOrDie(restConfig), Batch: batch.NewFactoryFromConfigOrDie(restConfig), Core: core.NewFactoryFromConfigOrDie(restConfig), - Apply: apply.New(k8s, apply.NewClientFactory(restConfig)), + Apply: apply.New(k8s, apply.NewClientFactory(restConfig)).WithDynamicLookup(), }, nil } diff --git a/vendor.go b/vendor.go index 1131d5063d..2583c68b2f 100644 --- a/vendor.go +++ b/vendor.go @@ -12,7 +12,6 @@ import ( _ "github.com/opencontainers/runc/contrib/cmd/recvtty" _ "github.com/opencontainers/runc/libcontainer/nsenter" _ "github.com/opencontainers/runc/libcontainer/specconv" - _ "k8s.io/kubernetes/cmd/hyperkube" ) func main() {}