From ac1e5081f36e8ef395e496ac1c35db1f5c67cbd6 Mon Sep 17 00:00:00 2001 From: Chris Lee Date: Mon, 23 Dec 2024 14:36:17 -0700 Subject: [PATCH] [rptest] Use HTTPS for metrics on opV2 --- tests/rptest/services/redpanda.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/rptest/services/redpanda.py b/tests/rptest/services/redpanda.py index 4ef24beda33a..a36f3e327101 100644 --- a/tests/rptest/services/redpanda.py +++ b/tests/rptest/services/redpanda.py @@ -2140,8 +2140,10 @@ def metrics( if metrics_endpoint == MetricsEndpoint.PUBLIC_METRICS: text = self._cloud_cluster.get_public_metrics() else: + # operator V2 clusters use HTTPS for all the things + p = '-k https' if self.is_operator_v2_cluster() else 'http' text = self.kubectl.exec( - 'curl -f -s -S http://localhost:9644/metrics', pod.name) + f'curl -f -s -S {p}://localhost:9644/metrics', pod.name) return text_string_to_metric_families(text) def metrics_sample(