Skip to content

Commit 8fd23d7

Browse files
committed
setup multiarch builder
1 parent 8a59696 commit 8fd23d7

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

docker/_builder/builder.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ fi
132132

133133
# Ensure QEMU is set up for cross-platform builds
134134
echo -n "Ensuring QEMU is configured for cross-platform builds..."
135-
if docker run --rm --privileged multiarch/qemu-user-static --reset -p yes > /dev/null 2>&1; then
135+
if docker run --rm --privileged tonistiigi/binfmt --install all > /dev/null 2>&1; then
136136
echo -e " [${GREEN}OK${NC}]"
137137
else
138138
echo -e " [${RED}FAIL${NC}]"

docker/_builder/setup_builder.sh

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,7 @@ fi
1919
if [ "$1" != "-y" ]; then
2020
echo "### Setting up Docker for Multi-Arch Builds."
2121
echo "### Requires Docker packages from https://get.docker.com/"
22-
echo "### Use on x64 only!"
23-
echo "### Run with -y if you fit the requirements!"
22+
echo "### Run with -y if you meet the requirements!"
2423
exit 0
2524
fi
2625

@@ -42,7 +41,7 @@ fi
4241

4342
# Ensure QEMU is set up for cross-platform builds
4443
echo -n "Ensuring QEMU is configured for cross-platform builds..."
45-
if docker run --rm --privileged multiarch/qemu-user-static --reset -p yes >/dev/null 2>&1; then
44+
if docker run --rm --privileged tonistiigi/binfmt --install all >/dev/null 2>&1; then
4645
echo -e " [${GREEN}OK${NC}]"
4746
else
4847
echo -e " [${RED}FAIL${NC}]"
@@ -95,5 +94,5 @@ echo " docker login -u <username>"
9594
echo " docker login ghcr.io -u <username>"
9695
echo
9796
echo -e "${BLUE}Fix segmentation faults when building arm64 images:${NC}"
98-
echo " docker run --rm --privileged multiarch/qemu-user-static --reset -p yes"
97+
echo " docker buildx rm mybuilder && docker run --rm --privileged tonistiigi/binfmt --install all"
9998
echo

0 commit comments

Comments
 (0)