Skip to content

Commit

Permalink
test: Fix i386 tests with latest podman
Browse files Browse the repository at this point in the history
This now requires specifying `--arch i386` explicitly.
  • Loading branch information
martinpitt committed Dec 19, 2024
1 parent faa96fd commit a4485a1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion tests/run-alpine
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ else
RUNC="sudo docker"
fi

$RUNC run --interactive ${OPTS:-} --volume `pwd`:/source:ro ${1:-docker.io/alpine} /bin/sh <<EOF
IMAGE="${1:-docker.io/alpine}"
[ "${IMAGE%i386*}" = "$IMAGE" ] || OPTS="${OPTS:-} --arch i386"

$RUNC run --interactive ${OPTS:-} --volume `pwd`:/source:ro "$IMAGE" /bin/sh <<EOF
# avoid meson exit code 125; https://github.com/containers/podman/issues/11540
trap '[ \$? -eq 0 ] || exit 1' EXIT
Expand Down
5 changes: 4 additions & 1 deletion tests/run-apt
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,12 @@ else
RUNC="sudo docker"
fi

IMAGE="${1:-docker.io/amd64/ubuntu:rolling}"
[ "${IMAGE%i386*}" = "$IMAGE" ] || OPTS="${OPTS:-} --arch i386"

[ -n "${PUBLISH_TAR:-}" ] || MOUNT_MODE=":ro"

$RUNC run --interactive ${RUNC_OPTIONS:-} ${OPTS:-} --volume `pwd`:/source${MOUNT_MODE:-} ${1:-docker.io/amd64/ubuntu:rolling} /bin/sh << EOF
$RUNC run --interactive ${RUNC_OPTIONS:-} ${OPTS:-} --volume `pwd`:/source${MOUNT_MODE:-} "$IMAGE" /bin/sh << EOF
set -ex
# avoid meson exit code 125; https://github.com/containers/podman/issues/11540
Expand Down

0 comments on commit a4485a1

Please sign in to comment.