访问Kubernetes Web UI(仪表板) [英] Accessing Kubernetes Web UI (Dashboard)

查看:105
本文介绍了访问Kubernetes Web UI(仪表板)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经安装了带有Kubeadm的Kubernetes工具,然后遵循文档安装Web UI(仪表板). Kubernetes已在一个节点实例(即污点主节点)中安装并运行.

I have installed a Kubernetes with Kubeadm tool, and then followed the documentation to install the Web UI (Dashboard). Kubernetes is installed and running in one node instance which is a taint master node.

但是,我无法通过https://<kubernetes-master>/ui访问Web UI.相反,我可以在https://<kubernetes-master>:6443/ui上访问它.

However, I'm not able to access the Web UI at https://<kubernetes-master>/ui. Instead I can access it on https://<kubernetes-master>:6443/ui.

我该如何解决?

推荐答案

您用来访问仪表板的URL是API服务器上的终结点.默认情况下,kubeadm将API服务器部署在端口6443上,而不是部署在443上,这是需要通过https访问仪表板而无需在URL中指定端口(即https://<kubernetes-master>/ui)的API服务器

The URL you are using to access the dashboard is an endpoint on the API Server. By default, kubeadm deploys the API server on port 6443, and not on 443, which is what you would need to access the dashboard through https without specifying a port in the URL (i.e. https://<kubernetes-master>/ui)

您可以通过多种方式公开和访问仪表板.这些是通过增加复杂性来排序的:

There are various ways you can expose and access the dashboard. These are ordered by increasing complexity:

  • 如果这是一个开发/测试集群,则可以尝试使用--api-port标志服务公开仪表板.
  • 部署入口控制器,并为仪表板定义一个入口点.
  • li>
  • If this is a dev/test cluster, you could try making kubeadm deploy the API server on port 443 by using the --api-port flag exposed by kubeadm.
  • Expose the dashboard using a service of type NodePort.
  • Deploy an ingress controller and define an ingress point for the dashboard.

这篇关于访问Kubernetes Web UI(仪表板)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆