到Docker 官网https://www.docker.com/
Docker Desktop Installer-Win.exe 2023-09版本是4.23
接受服务继续安装
打开 控制面板》程序》启用或关闭Windows功能, 选中Hyper-V后点击确定,再确定重启电脑进行配置
重启后报“wsl kernerl version too low”
到 Docker 的设置页面,找到Kubenetes,选中Enable Kubenetes,单击Apply&restart
当左下角出现 Kubenetes 的 logo,并逐步变为绿色,Kubenetes就运行起来了
通过 kubectl 来安装Kubernetes Dashboard 2.7
kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/v2.7.0/aio/deploy/recommended.yaml
C:\Users\Administrator>kubectl proxy
Starting to serve on 127.0.0.1:8001
http://localhost:8001/api/v1/namespaces/kubernetes-dashboard/services/https:kubernetes-dashboard:/proxy/
访问web界面,需要输入token才可以登录
kubectl create serviceaccount dashboard-admin -n kube-system
kubectl create clusterrolebinding dashboard-admin --clusterrole=cluster-admin --serviceaccount=kube-system:dashboard-admin
kubectl -n kube-system create token dashboard-admin