kubernetes dashboard v1.6.0 install

官方參考網址:git

              https://github.com/kubernetes/dashboard
              https://github.com/kubernetes/heapster
              
              http://kubernetes.io/docs/user-guide/ui
              https://github.com/kubernetes/heapster/blob/master/docs/influxdb.mdgithub

Internet在線安裝, 可用官方命令:
# kubectl create -f https://git.io/kube-dashboarddocker

 

下面介紹將必要組件下載到本地,並修改後,實現本地安裝:bash


1. dashboard image 下載curl

docker pull hub.c.163.com/bamboo/kubernetes-dashboard-amd64:v1.6.0
docker pull hub.c.163.com/hzwangxing02/heapster:influxdb-v1.1.1
docker pull hub.c.163.com/hzwangxing02/heapster:grafana-v4.0.2
docker pull hub.c.163.com/hzwangxing02/heapster:v1.3.0

2. 將dashboard image 打標籤,並上傳到本地registryide

# docker tag hub.c.163.com/bamboo/kubernetes-dashboard-amd64:v1.6.0 ispcdocker.com/kubernetes-dashboard-amd64:v1.6.0   
# docker tag hub.c.163.com/hzwangxing02/heapster:influxdb-v1.1.1 ispcdocker.com/heapster-influxdb-amd64:v1.1.1
# docker tag hub.c.163.com/hzwangxing02/heapster:grafana-v4.0.2 ispcdocker.com/heapster-grafana-amd64:v4.0.2
# docker tag hub.c.163.com/hzwangxing02/heapster:v1.3.0 ispcdocker.com/heapster-amd64:v1.3.0

# docker pull ispcdocker.com/kubernetes-dashboard-amd64:v1.6.0

...

3. install YAML文件下載ui

https://raw.githubusercontent.com/kubernetes/dashboard/master/src/deploy/kubernetes-dashboard.yaml
https://github.com/kubernetes/heapster/blob/master/deploy/kube-config/influxdb/influxdb.yaml
https://github.com/kubernetes/heapster/blob/master/deploy/kube-config/influxdb/grafana.yaml
https://github.com/kubernetes/heapster/blob/master/deploy/kube-config/influxdb/heapster.yaml

# mkdir dashboard && mv *.yaml dashboard

 

4. 修改image registry到本地google

# sed -i "s|gcr.io/google_containers|ispcdocker.com|g" ./dashboard/*.yaml

5. 開始安裝url

# kubectl --kubeconfig /etc/kubernetes/admin.conf create -f ./dashboard

6. 設定proxy port nat ,並訪問spa

# kubectl proxy --address='0.0.0.0' --port=8001 --accept-hosts='^*$' &

curl -L http://kubernetes-master-ip:8001/ui


7. 部署後查看dashboard服務信息:
# kubectl --namespace=kube-system  describe service/kubernetes-dashboard

 

---更新: hub.c.163.com 可能被關閉,容器鏡像,可從阿里下載:https://dev.aliyun.com

相關文章
相關標籤/搜索