Created
July 28, 2020 22:20
-
-
Save chavafg/708e34855a0e50c8b6ec168a6fd51e0d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/kata-webhook/main.go b/kata-webhook/main.go | |
index 71cad03..b2ba8af 100644 | |
--- a/kata-webhook/main.go | |
+++ b/kata-webhook/main.go | |
@@ -49,6 +49,10 @@ func annotatePodMutator(ctx context.Context, obj metav1.Object) (bool, error) { | |
return false, nil | |
} | |
+ if pod.GetNamespace() == "sonobuoy" { | |
+ fmt.Println("sonobuoy pods will not be changed to kata," pod.GetNamespace(), pod.GetName()) | |
+ } | |
+ | |
for i := range pod.Spec.Containers { | |
if pod.Spec.Containers[i].SecurityContext != nil { | |
if *pod.Spec.Containers[i].SecurityContext.Privileged { |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment