Kubernetes(十三)部署Web UI(Dashboard)
一、在master安装
kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/v2.0.0-beta8/aio/deploy/recommended.yaml kubectl apply -f recommended.yaml注意:默认的官方没有暴露外部端口,我们自己设置以下nodePort: 30001or使用我们准备的yaml
kubectl apply -f dashboard.yaml 二、查看podkubectl get pods -n kubernetes-dashboard输出以下内容NAME READY STATUS RESTARTS AGEdashboard-metrics-scraper-76585494d8-sbzjv 1/1 Running 0 2m6skubernetes-dashboard-5996555fd8-fc7zf 1/1 Running 2 2m6s三、查看端口 kubectl get pods,svc -n kubernetes-dashboard 输出以下内容 NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGEservice/dashboard-metrics-scraper ClusterIP 10.0.0.8 <none> 8000/TCP 16mservice/kubernetes-dashboard NodePort 10.0.0.88 <none> 443:30001/TCP 16m 四、访问控制面板 使用任意node节点IP+端口即可访问 https://106.14.72.***:30001/ 五、访问成功后我们看到 我们使用token方式来登录,创建service account并绑定默认cluster-admin管理员集群角色 六、下载我们准备好的yaml文件,执行 dashboard-adminuser.yaml373 bytes kubectl apply -f dashboard-adminuser.yaml
七、获取token
kubectl -n kubernetes-dashboard describe secret $(kubectl -n kubernetes-dashboard get secret | grep admin-user | awk ‘{print $1}‘)
八、在登录界面填入token即可访问
相关推荐
朱培知浅ZLH 2020-11-16
cdbdqn00 2020-11-12
达观数据 2020-11-11
JustinChia 2020-11-11
远远的山 2020-11-09
jingtao 2020-11-08
大叔比较胖 2020-10-30
gracecxj 2020-10-30
onepiecedn 2020-10-29
kunyus 2020-10-28
JustHaveTry 2020-10-27
锋锋 2020-10-26
hubanbei00的家园 2020-10-25
谢恩铭 2020-10-23
btqszl 2020-10-21
kaidiphp 2020-10-13
guchengxinfen 2020-10-12
liverlife 2020-10-10
BigDataMining 2020-10-08