Skip to content

Commit

Permalink
Test setting compat_uts_machine=armv6l
Browse files Browse the repository at this point in the history
Signed-off-by: Kyle Harding <[email protected]>
  • Loading branch information
klutchell committed Dec 14, 2023
1 parent 9011338 commit 87929be
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 12 deletions.
9 changes: 3 additions & 6 deletions docker-compose.test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,7 @@ services:
- sut:latest
hostname: alpine-test
environment:
- DOCKERHUB_USERNAME=${DOCKERHUB_USERNAME:-}
- DOCKERHUB_PASSWORD=${DOCKERHUB_PASSWORD:-}
EXTRA_KERNEL_BOOT_ARGS: compat_uts_machine=armv6l

debian-test:
extends:
Expand All @@ -76,8 +75,7 @@ services:
- sut:latest
hostname: debian-test
environment:
- DOCKERHUB_USERNAME=${DOCKERHUB_USERNAME:-}
- DOCKERHUB_PASSWORD=${DOCKERHUB_PASSWORD:-}
EXTRA_KERNEL_BOOT_ARGS: compat_uts_machine=armv6l

ubuntu-test:
extends:
Expand All @@ -91,5 +89,4 @@ services:
- sut:latest
hostname: ubuntu-test
environment:
- DOCKERHUB_USERNAME=${DOCKERHUB_USERNAME:-}
- DOCKERHUB_PASSWORD=${DOCKERHUB_PASSWORD:-}
EXTRA_KERNEL_BOOT_ARGS: compat_uts_machine=armv6l
30 changes: 24 additions & 6 deletions test/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,20 @@ id

date

uname -a
case $(dpkg --print-architecture 2>/dev/null || apk --print-arch) in
x86_64)
uname -a | grep x86_64
setarch linux32 uname -m | tee /dev/stderr | grep x86_64
;;
aarch64)
uname -a | grep aarch64
setarch linux32 uname -m | tee /dev/stderr | grep armv6l
;;
*)
echo "Unsupported architecture!"
exit 1
;;
esac

df -h

Expand Down Expand Up @@ -51,15 +64,20 @@ if command -v ip >/dev/null 2>&1; then
ip route
fi

# nested virtualization is not available on aarch64
if [ -r /dev/kvm ]; then
case $(dpkg --print-architecture || apk --print-arch) in
x86_64)
ls -l /dev/kvm
test -w /dev/kvm

test -w /dev/kvm || test "$(id -u)" != 0
if which kvm-ok >/dev/null; then
kvm-ok
fi
fi
;;
*)
# https://github.com/balena-io-experimental/container-jail/issues/44
# https://github.com/firecracker-microvm/firecracker/issues/1721
echo "Nested KVM unavailable on this architecture!"
;;
esac

if command -v npm >/dev/null 2>&1; then
npm ping
Expand Down

0 comments on commit 87929be

Please sign in to comment.