【发布时间】:2020-01-31 19:04:49
【问题描述】:
我想通过 HTTPS 通过 Internet 访问 Prometheus Operator。
我通过 HELM 部署了 Prometheus 并提供了以下 custom-vault.yml
图表版本:
kube-prometheus-0.0.105
nginx-ingress-0.31.0
部署:
helm install coreos/kube-prometheus --name kube-prometheus --set global.rbacEnable=false \
--namespace monitoring -f custom-vault.yml
我的期望: 我想通过 URL 浏览 Prometheus https://example.com/prometheus
我的 custom-vault.yml
prometheus:
ingress:
enabled: true
annotations:
kubernetes.io/ingress.class: nginx
nginx.ingress.kubernetes.io/rewrite-target: /
tls:
- secretName: tls-secret
hosts:
- example.com
hosts:
- example.com
paths:
- /
#prometheusSpec:
#externalUrl: https://example.com/prometheus
会发生什么?
我可以联系到https://example.com/graph,但由于路径错误,CSS 文件无法加载。
当我尝试配置 https://example.com/prometheus/graph 时,CSS 也不起作用,当我点击前端警报时,我被重定向到 https://example.com/alerts 并出现“默认后端 404”错误。
serval 服务/Pod 的其他入口路由正在运行 Prometheus 也在工作 - 当我将端口暴露给 localhost 时,Prometheus 会正确显示。
【问题讨论】:
标签: kubernetes prometheus kubernetes-ingress azure-aks nginx-ingress