我部署了一个集群: https ://bitnami.com/stack/prometheus-operator/helm 和 https://github.com/prometheus-community/postgres_exporter
如何正确地将自己的指标添加到 postgres_exporter 导出的指标的 prometheus-operator 列表中?
我是这样尝试的:
helm upgrade kube-prometheus bitnami/kube-prometheus \
--set prometheus.additionalScrapeConfigs.enabled=true \
--set prometheus.additionalScrapeConfigs.type=internal \
--set prometheus.additionalScrapeConfigs.internal.jobList=
- job_name: 'prometheus-postgres-exporter'
static_configs:
- targets: ['prometheus-postgres-exporter.default:80']
但它不起作用('job_name:' 未添加到 Prometheus 配置中)。