Feature/ocu 184 allow binaries and containers to be built for architectures different than amd #343
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As per title, allow to customise the built images and binaries for 🍎 people and documenting the utilisation.
We basically use --platform when building to specify for which platform we want to build an image. At the same time we can customise for which architecture the Go binaries should be built for.
Based on the supplied ARCH and OS, a binary is created in a self-documented sub-folder, as follows:
It would be nice to collapse the different
Dockerfile
s andMakefile
s in components into a single one, so such customisation can be centralised. I'll start a thread in the chat about it.Tested locally:
make components
-> builds withlinux/amd64
by default. Running the containers works fine.make GOOS=linux GOARCH=arm64 CONTAINER_OS_ARCH=linux/arm64 components
-> builds withlinux/arm64
. Running the containers work.make GOOS=darwin GOARCH=arm64 component-binaries
-> build withdarwin/arm64
and I can exec the binaries fine on my machine.I would appreciate if you can try these commands yourself and if you have other pointers to what to test.
Minor: bumping
remark-cli
to v12.0.1 to suppress formatting errors.