prometheus-community/helm-charts

[kube-prometheus-stack] chart should support scrapeClasses

johgoe opened this issue · 0 comments

Is your feature request related to a problem ?

I'm using kube-prometheus-stack and try to use scrapeClasses (see https://github.com/prometheus-operator/prometheus-operator/pull/6113/files) with istio mtls but I didn't find a way to set this option via values.yaml

Describe the solution you'd like.

Add a new option in values.yaml which is copied to the prometheus spec scrapeClasses option

prometheus:
  prometheusSpec:
    scrapeClasses:
      - name: istio-mtls
        default: false
        tlsConfig:
          caFile: /etc/prometheus/secrets/istio.default/root-cert.pem
          certFile: /etc/prometheus/secrets/istio.default/cert-chain.pem
{{- if .Values.prometheus.prometheusSpec.scrapeClasses }}
  scrapeClasses:
{{ tpl (toYaml .Values.prometheus.prometheusSpec.scrapeClasses | indent 4) . }}
{{- end }}

Describe alternatives you've considered.

No alternatives

Additional context.

No response