From 6adba645f6ff3840edb8ee063740c521f5566d3d Mon Sep 17 00:00:00 2001 From: dlorenc Date: Tue, 13 Nov 2018 08:13:39 -0800 Subject: [PATCH] Remove both the CoreDNS and KubeDNS addons. Let Kubeadm install the correct DNS addon. --- pkg/minikube/assets/addons.go | 49 -------------------- pkg/minikube/bootstrapper/kubeadm/kubeadm.go | 7 +-- 2 files changed, 1 insertion(+), 55 deletions(-) diff --git a/pkg/minikube/assets/addons.go b/pkg/minikube/assets/addons.go index e4c7357bfb2b..329cef3b5662 100644 --- a/pkg/minikube/assets/addons.go +++ b/pkg/minikube/assets/addons.go @@ -89,55 +89,6 @@ var Addons = map[string]*Addon{ "storage-provisioner.yaml", "0640"), }, true, "storage-provisioner"), - "coredns": NewAddon([]*BinDataAsset{ - NewBinDataAsset( - "deploy/addons/coredns/coreDNS-controller.yaml", - constants.AddonsPath, - "coreDNS-controller.yaml", - "0640"), - NewBinDataAsset( - "deploy/addons/coredns/coreDNS-configmap.yaml", - constants.AddonsPath, - "coreDNS-configmap.yaml", - "0640"), - NewBinDataAsset( - "deploy/addons/coredns/coreDNS-svc.yaml", - constants.AddonsPath, - "coreDNS-svc.yaml", - "0640"), - NewBinDataAsset( - "deploy/addons/coredns/coreDNS-crbinding.yaml", - constants.AddonsPath, - "coreDNS-crbinding.yaml", - "0640"), - NewBinDataAsset( - "deploy/addons/coredns/coreDNS-sa.yaml", - constants.AddonsPath, - "coreDNS-sa.yaml", - "0640"), - NewBinDataAsset( - "deploy/addons/coredns/coreDNS-clusterrole.yaml", - constants.AddonsPath, - "coreDNS-clusterrole.yaml", - "0640"), - }, true, "coredns"), - "kube-dns": NewAddon([]*BinDataAsset{ - NewBinDataAsset( - "deploy/addons/kube-dns/kube-dns-controller.yaml", - constants.AddonsPath, - "kube-dns-controller.yaml", - "0640"), - NewBinDataAsset( - "deploy/addons/kube-dns/kube-dns-cm.yaml", - constants.AddonsPath, - "kube-dns-cm.yaml", - "0640"), - NewBinDataAsset( - "deploy/addons/kube-dns/kube-dns-svc.yaml", - constants.AddonsPath, - "kube-dns-svc.yaml", - "0640"), - }, false, "kube-dns"), "heapster": NewAddon([]*BinDataAsset{ NewBinDataAsset( "deploy/addons/heapster/influx-grafana-rc.yaml", diff --git a/pkg/minikube/bootstrapper/kubeadm/kubeadm.go b/pkg/minikube/bootstrapper/kubeadm/kubeadm.go index dce9a368a96e..e244be928f6b 100644 --- a/pkg/minikube/bootstrapper/kubeadm/kubeadm.go +++ b/pkg/minikube/bootstrapper/kubeadm/kubeadm.go @@ -162,12 +162,7 @@ func addAddons(files *[]assets.CopyableFile) error { return errors.Wrap(err, "adding minikube dir assets") } // bundled addons - for addonName, addonBundle := range assets.Addons { - // TODO(r2d4): Kubeadm ignores the kube-dns addon and uses its own. - // expose this in a better way - if addonName == "kube-dns" { - continue - } + for _, addonBundle := range assets.Addons { if isEnabled, err := addonBundle.IsEnabled(); err == nil && isEnabled { for _, addon := range addonBundle.Assets { *files = append(*files, addon)