From 61d0c77aeb6f8caf90f1202f3758d02b43ecead3 Mon Sep 17 00:00:00 2001 From: Chris Mark Date: Wed, 16 Mar 2022 17:24:40 +0000 Subject: [PATCH] Update integration.go --- .../module/kubernetes/test/integration.go | 24 ++++++++++++------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/metricbeat/module/kubernetes/test/integration.go b/metricbeat/module/kubernetes/test/integration.go index 6966e82406c..52b2dab3e22 100644 --- a/metricbeat/module/kubernetes/test/integration.go +++ b/metricbeat/module/kubernetes/test/integration.go @@ -79,10 +79,14 @@ func GetKubeProxyConfig(t *testing.T, metricSetName string) map[string]interface func GetSchedulerConfig(t *testing.T, metricSetName string) map[string]interface{} { t.Helper() return map[string]interface{}{ - "module": "kubernetes", - "metricsets": []string{metricSetName}, - "host": "${NODE_NAME}", - "hosts": []string{"localhost:10251"}, + "module": "kubernetes", + "metricsets": []string{metricSetName}, + "host": "${NODE_NAME}", + "hosts": []string{"https://0.0.0.0:10259"}, + "bearer_token_file": "/var/run/secrets/kubernetes.io/serviceaccount/token", + "ssl": map[string]interface{}{ + "verification_mode": "none", + }, } } @@ -90,9 +94,13 @@ func GetSchedulerConfig(t *testing.T, metricSetName string) map[string]interface func GetControllerManagerConfig(t *testing.T, metricSetName string) map[string]interface{} { t.Helper() return map[string]interface{}{ - "module": "kubernetes", - "metricsets": []string{metricSetName}, - "host": "${NODE_NAME}", - "hosts": []string{"localhost:10252"}, + "module": "kubernetes", + "metricsets": []string{metricSetName}, + "host": "${NODE_NAME}", + "hosts": []string{"https://0.0.0.0:10257"}, + "bearer_token_file": "/var/run/secrets/kubernetes.io/serviceaccount/token", + "ssl": map[string]interface{}{ + "verification_mode": "none", + }, } }