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.
Description
Cross-Platform Build and Testing
Summary of the Change
This change updates the Docker build process to support cross-platform builds using Docker Buildx. The platforms tested include:
linux/amd64
linux/arm64
linux/riscv64
linux/ppc64le
linux/s390x
linux/386
linux/mips64le
linux/mips64
linux/arm/v7
linux/arm/v6
Key updates include:
docker-compose.sh
script was updated to build images for multiple platforms using Docker Buildx.docker buildx build --platform
command to build for all specified platforms.METACALL_PLATFORM
variable is not set, the script defaults to all the platforms mentioned above.Issue Fixed
The issue fixed by this change is enabling cross-platform Docker builds and testing. This ensures that the Docker images for the application can be built and tested across various architectures (e.g.,
amd64
,arm64
,riscv64
, etc.), addressing any compatibility issues across platforms.Dependencies
docker-compose.yml
for building the images. Ensure Docker Compose is installed.Additional Information
--push
flag (which was intentionally avoided as per your request).Additional code testing
I went a step ahead and in order to check the validity of the code pushed the images to a personal image of metacall/core that I have created on Docker hub.
Type of change
Checklist:
make test
orctest -VV -R <test-name>
)../docker-compose.sh test &> output
and attached the output.OPTION_BUILD_ADDRESS_SANITIZER
or./docker-compose.sh test-address-sanitizer &> output
andOPTION_TEST_MEMORYCHECK
.OPTION_BUILD_THREAD_SANITIZER
or./docker-compose.sh test-thread-sanitizer &> output
.Helgrind
in case my code works with threading.make clang-format
in order to format my code and my code follows the style guidelines.