[feature] enable building ARM image on x86
This commit is contained in:
parent
a9c07a3d87
commit
2b642594c6
20
apps/docker-arm.sh
Executable file
20
apps/docker-arm.sh
Executable file
|
@ -0,0 +1,20 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
DIR=$(readlink -f $(dirname $0))
|
||||||
|
. $DIR/../env.sh
|
||||||
|
|
||||||
|
|
||||||
|
# let docker be able to build arm image on x86
|
||||||
|
if ! docker run --rm -t arm64v8/ubuntu uname -m; then
|
||||||
|
case "$PM" in
|
||||||
|
apt)
|
||||||
|
sudo apt-get install qemu binfmt-support qemu-user-static
|
||||||
|
;;
|
||||||
|
pacman)
|
||||||
|
# TODO
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
sudo docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
|
||||||
|
sudo docker run --rm -t arm64v8/ubuntu uname -m
|
||||||
|
fi
|
||||||
|
|
Loading…
Reference in New Issue
Block a user