0

我在 Ubuntu VM 上安装了 kubernetes 集群,还安装了 heapster。但是当我这样做时

wget http://127.0.0.1:8080/api/v1/proxy/namespaces/kube-system/services/heapster

我收到错误:

--2016-11-04 14:44:41--  http://127.0.0.1:8080/api/v1/proxy/namespaces/kube-system/services/heapster
Connecting to 127.0.0.1:8080... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: /api/v1/proxy/namespaces/kube-system/services/heapster/ [following]
--2016-11-04 14:44:42--  http://127.0.0.1:8080/api/v1/proxy/namespaces/kube-system/services/heapster/
Reusing existing connection to 127.0.0.1:8080.
HTTP request sent, awaiting response... 404 Not Found
2016-11-04 14:44:42 ERROR 404: Not Found.
4

2 回答 2

0

以下没有“代理”的 URL 对我有用:

http://127.0.0.1:8080/api/v1/namespaces/kube-system/services/heapster
于 2017-02-24T12:08:54.333 回答
0

通过代理查询时尝试以下操作

  • /api/v1/proxy/namespaces/kube-system/services/https:heapster/api/v1/model/namespaces/
  • /api/v1/proxy/namespaces/kube-system/services/heapster/api/v1/model/namespaces/
  • /api/v1/proxy/namespaces/kube-system/services/http:heapster/api/v1/model/namespaces/

这为 heapster 侦听器指定了一个端口和一些后缀。我假设您确实收到了响应,但响应是来自 heapster 的真正 404,因为未处理对 root 的请求。

heapster 模型的所有后缀都可以在这里找到:https ://github.com/kubernetes/heapster/blob/master/docs/model.md

于 2017-05-26T13:47:30.780 回答