【4】访问http://kube-apiserver:port
http://192.168.0.103:8080 查看所有请求url
http://192.168.0.103:8080/healthz/ping 查看健康状况
备注:/etc/hosts添加localhost 192.168.0.103 【5】安装kubernetes dashboard
# mkdir /usr/local/src/docker && cd /usr/local/src/docker
a,下载kubernetes-dashboard-no-rbac.yaml
# wget https://raw.githubusercontent.com/kubernetes/dashboard/master/src/deploy/kubernetes-dashboard-no-rbac.yaml
b,下载docker pull siriuszg/kubernetes-dashboard-amd64
# docker pull siriuszg/kubernetes-dashboard-amd64
备注:下载kubernetes-dashboard-amd64镜像花了比较多时间,最终通过https://hub.docker.com,搜索kubernetes-dashboard-amd64,找到镜像
下载
=========
[iyunv@localhost docker]# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
registry.access.redhat.com/rhel7/pod-infrastructure latest 34d3450d733b 12 weeks ago 205 MB
docker.io/mritd/kubernetes-dashboard-amd64 latest 75f167b703e6 6 months ago 86.27 MB
=========
c,修改kubernetes-dashboard-no-rbac.yaml
-----------------------------------
- name: kubernetes-dashboard
image: gcr.io/google_containers/kubernetes-dashboard-amd64:v1.6.0
-----------------------------------
改为
-----------------------------------
- name: kubernetes-dashboard
image: docker.io/mritd/kubernetes-dashboard-amd64
-----------------------------------
"# - --apiserver-host=http://my-address:port" 改为 "- --apiserver-host=http://192.168.0.103:8080"
d, 查看namespace
# kubectl get pods --all-namespaces | grep dashboard
no resources
e, install dashboard
# kubectl create -f kubernetes-dashboard-no-rbac.yaml
f,The easiest way to access Dashboard is to use kubectl. Run the following command in your desktop environment:
# kubectl proxy
Starting to serve on 127.0.0.1:8001
g,验证
[iyunv@localhost docker]# docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
538819330e57 docker.io/mritd/kubernetes-dashboard-amd64 "/dashboard --port=90" xxxx
6c271cd426825 registry.access.redhat.com/rhel7/pod-infrastructure:latest "/pod" xxxx
h,access ui
kubectl will handle authentication with apiserver and make Dashboard available at http://localhost:8001/ui
The UI can only be accessed from the machine where the command is executed. See kubectl proxy --help for more options.
The end
Refer to:
http://www.aspku.com/fuwuqi/203663.html
https://github.com/kubernetes/dashboard