Preliminary updates to CI on the road to building maintainable multiplatform container images #410
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.
This PR only modifies CI for now. Detailed change explanations are as follows:
The
make-docker-images
job matrix now defines arunner-platform
variable with definitions for a Ubuntu x86 and Ubuntu arm runner. This added variable results in the job now being run on two separate runners, building images for each platform, but a condition is defined on the subsequent "push" step which intentionally limits only the x86 images being pushed to DockerHub for now and not the arm images.A step has been added to install a specific version of Docker Engine on the runner and configure it to use the containerd image store which is needed to facilitate multiplatform image handling. It seems the GHA Ubuntu runners already install Docker Engine from Docker's APT repos, but with an older version. In order to keep the CI builds more stable, this PR defines an environment variable specifying the exact version to be installed. The initial value for the variable is the current latest Docker Engine release as of 2024-02-25.
A step has been added to run the "binfmt" container image on the runner so that QEMU can be used to build container images for other platforms. Currently this QEMU functionally is NOT used and has proven to be problematic with the postgis builds.
As stated above, the step which pushes images to DockerHub has been modified to include a condition to only push images built on the x86 runners. This is intended to be temporary until multiplatform composite images are rolled into the CI.