Use specific image for user namespaces tests

Due to the lack of an existing /proc dir in the rootfs of busybox, there
seems to be a race between the mount of /proc and whether the root dir
is already readonly? May need investigation, but for now use an image
that has a /proc dir existing.

Signed-off-by: Phil Estes <estesp@amazon.com>
This commit is contained in:
Phil Estes 2021-03-19 22:51:32 -04:00
parent a47feaf462
commit 33776ada04
No known key found for this signature in database
GPG Key ID: FE2598126B196A38

View File

@ -55,6 +55,8 @@ import (
"golang.org/x/sys/unix"
)
const testUserNSImage = "mirror.gcr.io/library/alpine:latest"
// TestRegressionIssue4769 verifies the number of task exit events.
//
// Issue: https://github.com/containerd/containerd/issues/4769.
@ -1596,7 +1598,7 @@ func testUserNamespaces(t *testing.T, readonlyRootFS bool) {
)
defer cancel()
image, err = client.GetImage(ctx, testImage)
image, err = client.Pull(ctx, testUserNSImage, WithPullUnpack)
if err != nil {
t.Fatal(err)
}