kubespray安装kubernetes完成后kubenetes-dashboard安装

在上篇使用kuberspay无坑安装生产级Kubernetes集群,在安装完成后,若需安装kubernetes-dashboard,请进行下面操作:

  • 下载描述文件curl https://raw.githubusercontent.com/kubernetes/dashboard/master/src/deploy/kubernetes-dashboard.yaml -o kubernetes-dashboard.yaml
  • gcr.io/google_containers/kubernetes-dashboard-amd64修改为registry.cn-hangzhou.aliyuncs.com/google_images/kubernetes-dashboard-amd64
  • 执行:kubectl create -f kubernetes-dashboard.yaml
  • 查看执行结果
    wangyunfeideMBP:kubespray wangyunfei$ kubectl get pod
    NAME                                  READY     STATUS    RESTARTS   AGE
    kube-apiserver-node1                  1/1       Running   0          3d
    kube-controller-manager-node1         1/1       Running   0          3d
    kube-dns-69997447-783dz               3/3       Running   0          3d
    kube-proxy-node1                      1/1       Running   0          3d
    kube-proxy-node2                      1/1       Running   0          3d
    kube-proxy-node3                      1/1       Running   0          3d
    kube-scheduler-node1                  1/1       Running   0          3d
    kubedns-autoscaler-2506230242-1vcgk   1/1       Running   0          3d
    kubernetes-dashboard-27199923-qqgrq   1/1       Running   0          1m
    nginx-proxy-node2                     1/1       Running   0          3d
    nginx-proxy-node3                     1/1       Running   0          3d

  • 查看页面,执行kubectl proxy,访问http://127.0.0.1:8001/ui

    kubespray安装kubernetes完成后kubenetes-dashboard安装

 源码地址:http://www.wisely.top/2017/07/04/kubespray-kubernetes-dashboard/

相关推荐