Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding explicit build-args for linux amd64 #1369

Closed

Conversation

jonathancross
Copy link
Contributor

When attempting to build the latest firmware, the TARGETPLATFORM and TARGETARCH were not being automatically populated from the --platform linux/amd64 as assumed here:
https://github.com/BitBoxSwiss/bitbox02-firmware/blob/master/Dockerfile#L24

This lead to confusing errors late in the build process.

Docker indicates these AARGs are only set when using the buildkit backend: https://docs.docker.com/reference/dockerfile/#automatic-platform-args-in-the-global-scope

I'm using docker commandline, on PopOS.

In order to prevent issues for myself and other users, I am making this PR to explicitly set these parameters instead of relying on invisible buildkit magic.

@benma benma requested a review from NickeZ February 8, 2025 17:26
@benma
Copy link
Collaborator

benma commented Feb 8, 2025

I assume you'd also need to change this then:

./scripts/container.sh build --pull --force-rm --no-cache -t shiftcrypto/firmware_v2:$(shell cat .containerversion) .

@NickeZ any idea why this is needed for @jonathancross while it seems to work fine for everyone else so far?

@jonathancross
Copy link
Contributor Author

Please ignore. It turns out that my version of docker was old.

@jonathancross jonathancross deleted the docker-build-args branch February 8, 2025 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants