- Security
Enable mTLS for custom metrics
To enable Strict mTLS scraping for a component, configure the Istio TLS certificates in the corresponding ServiceMonitor:
Click to copy
---apiVersion: monitoring.coreos.com/v1kind: ServiceMonitormetadata: name: metrics namespace: kyma-system labels: prometheus: monitoring example: monitoring-custom-metricsspec: selector: matchLabels: k8s-app: metrics targetLabels: - k8s-app endpoints: - port: web interval: 10s scheme: https tlsConfig: caFile: /etc/prometheus/secrets/istio.default/root-cert.pem certFile: /etc/prometheus/secrets/istio.default/cert-chain.pem keyFile: /etc/prometheus/secrets/istio.default/key.pem insecureSkipVerify: true # Prometheus does not support Istio security naming; skip verifying the target Pod certificate namespaceSelector: any: true