From 6d93a09b7907fcdc02d9a787fb24214d4020faf3 Mon Sep 17 00:00:00 2001 From: Quentin Bisson Date: Wed, 10 Apr 2024 14:06:52 +0200 Subject: [PATCH] Update pkg/monitoring/prometheusagent/secret.go --- pkg/monitoring/prometheusagent/secret.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkg/monitoring/prometheusagent/secret.go b/pkg/monitoring/prometheusagent/secret.go index fcc2b42a..0e2b6a37 100644 --- a/pkg/monitoring/prometheusagent/secret.go +++ b/pkg/monitoring/prometheusagent/secret.go @@ -76,6 +76,9 @@ func readRemoteWritePasswordFromSecret(secret corev1.Secret) (string, error) { } for _, rw := range remoteWriteConfig.PrometheusAgentConfig.RemoteWrite { + // We read the secret from the remote write configuration named `prometheus-meta-operator` only + // as this secret is generated per cluster. + // This will eventually be taken care of by the multi-tenancy contoller if rw.Name == remoteWriteName { return rw.Password, nil }