ci: add multi-arch Docker image test workflow - #448
Conversation
33b3745 to
07a7f2d
Compare
07a7f2d to
f0b1ef2
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f0b1ef2c40
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Signed-off-by: Darafei Praliaskouski <me@komzpa.net>
f4f3fdf to
c9481ec
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c9481ec294
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Signed-off-by: Darafei Praliaskouski <me@komzpa.net>
c9481ec to
685f42b
Compare
Overview
This PR is a cleaned-up follow-up to the earlier multi-architecture work in #432 and the
ImreSamu/docker-postgis-testprototype.The practical problem is that Docker PostGIS has accumulated several ARM-related PRs and comments, but the hard part is not only "build an arm64 image". The publish workflow also has to prove that both architectures were tested, assemble the manifest list from the correct per-platform digests, and avoid accidentally publishing a partial tag when one side of the matrix failed.
This PR keeps that risk contained by adding a separate trial workflow,
.github/workflows/test.yml, while leaving the existing.github/workflows/main.ymluntouched.What This Adds
ubuntu-24.04andubuntu-24.04-arm.docker-library/official-imagestests used by the existing workflow before any publish-capable step.linux/amd64andlinux/arm64.linux/arm64/v8, when the expected platform is the genericlinux/arm64.Safety Model
PR runs are test-only. They build and test images, but they do not push Docker Hub tags or update the Docker Hub description.
The publish-capable path is gated to non-PR runs on canonical
master. Even there, it publishes to the configured test repository,postgis/docker-postgis-test, not directly to the productionpostgis/postgisrepository.The workflow also uses run-id and run-attempt-scoped image/artifact names, plus per-tag manifest concurrency, so reruns do not collide with older artifacts or with another run assembling the same tag.
Matrix Generation
The workflow uses a generated
matrix.ymlso the CI target list follows the image directories instead of being hand-maintained in the workflow file.update.shnow regenerates that matrix. The current generated matrix includes the active release targets from the repository, including PostgreSQL 19 beta targets and current Alpine/PostGIS tags, while skipping placeholder or development-only targets such as the17-3.6Debian placeholder and*-masterentries for the required release matrix.Local Validation
bash -n update.sh ci/matrix.sh ci/test-image.sh ci/push-manifest.sh ci/prepare-dockerhub-readme.shshellcheck ci/matrix.sh ci/test-image.sh ci/push-manifest.sh ci/prepare-dockerhub-readme.shRUNNER_PLATFORMS_JSON='["ubuntu-24.04","ubuntu-24.04-arm"]' bash ci/matrix.sh.github/workflows/test.ymlandmatrix.ymlgit diff --checkactionlint .github/workflows/*.ymllinux/arm64/v8satisfying expectedlinux/arm6417-3.5:docker build -t postgis/postgis:ci-local-17-3.5-default 17-3.5bash ci/test-image.sh postgis/postgis:ci-local-17-3.5-defaultpostgres-basics,postgres-initdb, andpostgis-basicspassing