diff --git a/tests/integration/kubernetes/k8s-policy-pod.bats b/tests/integration/kubernetes/k8s-policy-pod.bats index 140507fdf0..d8ed91c9d9 100644 --- a/tests/integration/kubernetes/k8s-policy-pod.bats +++ b/tests/integration/kubernetes/k8s-policy-pod.bats @@ -216,7 +216,7 @@ test_pod_policy_error() { # Execute commands allowed by the policy. pod_exec_allowed_command "${pod_name}" "echo" "livenessProbe" "test" - pod_exec_allowed_command "${pod_name}" "sh" "-c" "ls -l /" + pod_exec_allowed_command "${pod_name}" "echo" "-n" "readinessProbe with space characters" pod_exec_allowed_command "${pod_name}" "echo" "startupProbe" "test" # Try to execute commands disallowed by the policy. diff --git a/tests/integration/kubernetes/runtimeclass_workloads/k8s-policy-pod.yaml b/tests/integration/kubernetes/runtimeclass_workloads/k8s-policy-pod.yaml index d6bc21afee..db4a988d67 100644 --- a/tests/integration/kubernetes/runtimeclass_workloads/k8s-policy-pod.yaml +++ b/tests/integration/kubernetes/runtimeclass_workloads/k8s-policy-pod.yaml @@ -11,8 +11,10 @@ spec: terminationGracePeriodSeconds: 0 runtimeClassName: kata containers: - - name: busybox - image: quay.io/prometheus/busybox:latest + - name: prometheus + image: quay.io/prometheus/prometheus:latest + command: + - /bin/sh env: - name: KUBE_CONFIG_1 valueFrom: @@ -40,9 +42,9 @@ spec: readinessProbe: exec: command: - - "sh" - - "-c" - - "ls -l /" + - "echo" + - "-n" + - "readinessProbe with space characters" startupProbe: exec: command: