2

使用的命令:

git clone https://github.com/helm/charts.git

cd charts/stable/prometheus

helm install prometheus . --namespace monitoring --set rbac.create=true

运行第三个命令后,出现以下错误:

在此处输入图像描述

任何人请帮我解决这个问题...

谢谢...

4

2 回答 2

0

GitHub 页面上,您可以看到它已弃用此 repo:

已弃用并移至https://github.com/prometheus-community/helm-charts

所以我建议添加和使用Prometheus Community Kubernetes Helm Charts存储库:

helm repo add prometheus-community https://prometheus-community.github.io/helm-charts

然后,您可以使用以下命令安装带有标志的 Prometheus:

helm install prometheus prometheus-community/prometheus --namespace monitoring --set rbac.create=true

如果您真的想坚持使用旧存储库中的版本,则不必将存储库克隆到您的主机。只需按照存储库页面中的步骤操作即可。确保您已https://charts.helm.sh/stable通过运行将存储库添加到 helm 中helm repo list。如果没有,请使用以下命令添加:

helm repo add stable https://charts.helm.sh/stable

然后,您可以安装图表:

helm install prometheus stable/prometheus --namespace monitoring --set rbac.create=true
于 2021-10-06T14:12:44.933 回答
0

如果您不想安装状态指标,可以尝试

要在安装期间禁用依赖项,请在values.yaml文件中设置kubeStateMetrics.enabledfalse

values.yaml文件中的行号。435改错_

完成文件编辑后,运行相同的命令。

helm install prometheus . --namespace monitoring --set rbac.create=true

参考文档:https ://github.com/prometheus-community/helm-charts/tree/main/charts/prometheus#dependencies

或者

你可以试试

  1. git 克隆https://github.com/helm/charts.git
  2. cd 图表/稳定/普罗米修斯
  3. helm依赖更新

kube-state-metrics如果存在,请尝试在文件夹中运行上述命令

  1. 掌舵安装普罗米修斯。--命名空间监控 --set rbac.create=true

你还需要安装prometheus的依赖

阅读更多:https ://github.com/prometheus-community/helm-charts/blob/main/charts/kube-prometheus-stack/README.md#dependencies

于 2021-10-01T16:45:53.467 回答