From bd4a78f38d9b30935acd0ff16820cf1ed1c52abd Mon Sep 17 00:00:00 2001 From: JD Harrington Date: Thu, 18 Jul 2024 12:07:42 -0400 Subject: [PATCH] Exclude shell pods from logging to Datadog --- cmd/shell.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cmd/shell.go b/cmd/shell.go index 7380111..83934ab 100644 --- a/cmd/shell.go +++ b/cmd/shell.go @@ -5,7 +5,6 @@ import ( "os" "os/exec" "os/user" - "strconv" "strings" "syscall" @@ -126,7 +125,7 @@ func buildShellKubectlArgs(podName string, image string, istioEnabled bool, serv overrides.Metadata.Name = "" overrides.Metadata.GenerateName = podName + "-" overrides.Metadata.Annotations = map[string]string{ - "sidecar.istio.io/inject": strconv.FormatBool(istioEnabled), + "ad.datadoghq.com/exclude": "true", } if serviceaccount != "" {