3
votes

I can not remove kubernetes-dashboard from Minikube. I tried deleting the deployment "deployment.apps/kubernetes-dashboard" multiple times. But it gets recreated automatically in a few seconds.

I am using the following command to delete the deployment:

kubectl delete deployment.apps/kubernetes-dashboard -n kube-system

I even tried to edit the deployment by setting the replica count to zero. But even it gets reset automatically after a few seconds.

The same thing happens for nginx-ingress deployment in kube-system.

3
Please do share the yaml or something that you gave to start the deploymentGokul C
I enabled the dashboard by "minikube dashboard --url". Didn't use any external yaml file.Nitesh
It is a possibility that the dashboard is static deployment in minikube, and it's file should be present in /etc/kubernetes/manifests. If it is present there, by removing that file it will automatically delete it. I am not sure that it is static deployment in minikube or not. Please checkPrafull Ladha
@PrafullLadha Actually, It's not present in the menifests directory.Nitesh

3 Answers

5
votes

I had to disable the dashboard addon using minikube first. Then deleting the deployment did work for me.

minikube addons disable dashboard

And in case of ingress:

minikube addons disable ingress
2
votes

Try the below command:

kubectl delete -f https://raw.githubusercontent.com/kubernetes/dashboard/v2.0.0-rc5/aio/deploy/recommended.yaml

Enter image description here

1
votes

Please do try the following:

kubectl get secret,sa,role,rolebinding,services,deployments --namespace=kube-system | grep dashboard