Skip to content

Commit 01fb3aa

Browse files
committed
test/e2e: fix "with unsafe hostPath subpaths" test
A recent pasta update changed the selinux rules and we now run pasta under pasta_t and no longer the container_runtime_t type. The pasta type has much stricter type rules on what the file we hand it must be labelled. This test tries to mount the runroot which gets relabeled with the container_file_t type but that means pasta can no longer access its pid file we give it. To fix this test here simply mount a subdir. see #26473 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
1 parent 7808625 commit 01fb3aa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/e2e/play_kube_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5549,7 +5549,7 @@ spec:
55495549
})
55505550

55515551
It("with unsafe hostPath subpaths", func() {
5552-
hostPathLocation := podmanTest.TempDir
5552+
hostPathLocation := filepath.Join(podmanTest.TempDir, "vol")
55535553

55545554
Expect(os.MkdirAll(filepath.Join(hostPathLocation, "testing"), 0755)).To(Succeed())
55555555
Expect(os.Symlink("/", filepath.Join(hostPathLocation, "testing", "symlink"))).To(Succeed())

0 commit comments

Comments
 (0)