我是kubernetes的新手。我刚刚遵循了这个指南,并有一个vagrant / kubernetes集群:https://coreos.com/kubernetes/docs/latest/kubernetes-on-vagrant.html
我有兴趣查看ui,所以我按照这里的说明进行操作:http://kubernetes.io/docs/user-guide/ui/#deploying-the-dashboard-ui
$ kubectl proxy
Starting to serve on 127.0.0.1:8001
在浏览到上述IP:PORT时,会提供<h3>Unauthorized</h3>
。所以,我对URI后缀/ui
,我们得到:
// 127.0.0.1:8001/ui redirected to http://localhost:8001/api/v1/proxy/namespaces/kube-system/services/kubernetes-dashboard
{
"kind": "Status",
"apiVersion": "v1",
"metadata": {},
"status": "Failure",
"message": "no endpoints available for service \"kubernetes-dashboard\"",
"reason": "ServiceUnavailable",
"code": 503
}
或许相关的是:
$ kubectl cluster-info
Kubernetes master is running at https://172.17.4.101:443
Heapster is running at https://172.17.4.101:443/api/v1/proxy/namespaces/kube-system/services/heapster
KubeDNS is running at https://172.17.4.101:443/api/v1/proxy/namespaces/kube-system/services/kube-dns
kubernetes-dashboard is running at https://172.17.4.101:443/api/v1/proxy/namespaces/kube-system/services/kubernetes-dashboard
$ kubectl get services
NAME CLUSTER-IP EXTERNAL-IP PORT(S) AGE
kubernetes 10.3.0.1 <none> 443/TCP 36m
我看到了另一个SO帖子Kubernetes dashboard keeps pending with message: no endpoints available for service "kubernetes-dashboard",并发现了get pods
和describe pod <pod-name> --namespace=kube-system
。
所以,我跑了kubectl describe pod kubernetes-dashboard-3543765157-94gj9 --namespace="kube-system"
,产生了:https://gist.github.com/cdaringe/b972bf5a95c9f2a7cb8386ef6bf2252b
答案 0 :(得分:0)
最终,我的集群没有节点,因此UI服务无法登陆和运行! API仍尝试代理它,这就是它报告“没有端点”的原因 - 没有主机端点为内容提供服务。仍然没有弄清楚为什么我的流浪群集没有部署节点。即时猜测工人们从未下载过这个小册子并加入了。