mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-08-02 08:17:01 +00:00
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 <dmihai@microsoft.com>
This commit is contained in:
parent
d2d8d2e519
commit
db1ca4b665
@ -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
|
||||
|
Loading…
Reference in New Issue
Block a user