Skip to content

Commit

Permalink
TARGETPLATFORM needs to be set
Browse files Browse the repository at this point in the history
Co-authored-by: yubiuser <[email protected]>
Signed-off-by: Adam Warner <[email protected]>
  • Loading branch information
PromoFaux and yubiuser committed Oct 22, 2023
1 parent ae90e9c commit 5c7ff5c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions build-and-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,5 @@ docker run --rm \
--env PIPENV_CACHE_DIR="$(pwd)/.pipenv" \
--env GIT_TAG="${GIT_TAG}" \
--env PY_COLORS=1 \
--env TARGETPLATFORM="${PLATFORM}" \
${enter} image_pipenv
2 changes: 1 addition & 1 deletion src/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ RUN git clone --depth 1 --single-branch --branch ${WEB_BRANCH} https://github.co
elif [ "$TARGETPLATFORM" = "linux/386" ]; then FTLARCH=386; \
elif [ "$TARGETPLATFORM" = "linux/arm/v6" ]; then FTLARCH=armv6; \
elif [ "$TARGETPLATFORM" = "linux/arm/v7" ]; then FTLARCH=armv7; \
elif [ "$TARGETPLATFORM" = "linux/arm64" ]; then FTLARCH=arm64; \
elif [ "$TARGETPLATFORM" = "linux/arm64/v8" ]; then FTLARCH=arm64; \
elif [ "$TARGETPLATFORM" = "linux/riscv64" ]; then FTLARCH=riscv64; \
else FTLARCH=amd64; fi \
&& echo "Arch: ${TARGETPLATFORM}, FTLARCH: ${FTLARCH}" \
Expand Down
2 changes: 1 addition & 1 deletion test/cmd.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env sh
set -eux

docker buildx build ./src --tag pihole:${GIT_TAG} --no-cache
docker buildx build ./src --build-arg TARGETPLATFORM="${TARGETPLATFORM}" --tag pihole:${GIT_TAG} --no-cache
docker images pihole:${GIT_TAG}

# auto-format the pytest code
Expand Down

1 comment on commit 5c7ff5c

@pralor-bot
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit has been mentioned on Pi-hole Userspace. There might be relevant details there:

https://discourse.pi-hole.net/t/latest-docker-image-broken/65987/28

Please sign in to comment.