From db1ca4b665d12530177dc17d627d53ee0c13fcb7 Mon Sep 17 00:00:00 2001 From: Dan Mihai Date: Wed, 11 Sep 2024 18:50:19 +0000 Subject: [PATCH] tests: k8s-policy-pod: remove UID workaround Remove the workaround for #9928, now that genpolicy is able to convert user names from container images into the corresponding UIDs from these images. Signed-off-by: Dan Mihai --- tests/integration/kubernetes/k8s-policy-pod.bats | 9 --------- 1 file changed, 9 deletions(-) diff --git a/tests/integration/kubernetes/k8s-policy-pod.bats b/tests/integration/kubernetes/k8s-policy-pod.bats index 78dbf1d452..8e8f126b81 100644 --- a/tests/integration/kubernetes/k8s-policy-pod.bats +++ b/tests/integration/kubernetes/k8s-policy-pod.bats @@ -35,15 +35,6 @@ setup() { kubectl create -f "${priority_class_yaml}" - # This container image specifies user = "nobody", that corresponds to UID = 65534. - # genpolicy doesn't know yet how to convert the user name to UID (as described by - # https://github.com/kata-containers/kata-containers/issues/9928), so temporarily - # work around that limitation of the tool by explicitly settings runAsUser = 65534 - # in the YAML file. - yq -i \ - '.spec.containers[0].securityContext.runAsUser = 65534' \ - "${correct_pod_yaml}" - # Save some time by executing genpolicy a single time. if [ "${BATS_TEST_NUMBER}" == "1" ]; then # Save pre-generated yaml files