Draft
Modernize Docker build infrastructure: multi-arch GitHub Actions + buildkit strategy#222
Conversation
Copilot
AI
changed the title
[WIP] Update Docker build infrastructure for multi-platform support
Modernize Docker build infrastructure: multi-arch GitHub Actions + buildkit strategy
Jul 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Replaces the outdated single-arch CircleCI + GitHub Actions setup with the proven multi-platform buildkit strategy from
balena-photo-cropper. Adds fullarmhf/aarch64/x86_64matrix builds, GHA layer caching, buildkit secret mounts, and manifest merging.CI/CD
.github/workflows/docker-build.yml— replacesbuild.yml; usesdocker/bake-action@v5, full 3-arch matrix, separated "Write buildkit secrets" step, GHA cache injection, manifest merge in deploy job.circleci/config.ymland.github/workflows/build.ymlpermissions: contents: read / actions: writeon both jobs (least-privilege)docker-bake.hcl
REGISTRY,REGISTRY_IMAGE,GITHUB_SHAvariablescommontarget inheriting GHA cache (type=gha) — all service targets inherit itarmhf/aarch64/x86_64, each building all 4 services with platform-suffixed tags (arm32v7,arm64v8,amd64) plus branch-safe and SHA tagsmanifest-push.sh (new)
common.envforBALENA_PROJECTS, parsesREGISTRY/DOCKER_ORGfromdocker-bake.hcllatestonmain/developmentcommon.env
BALENA_PROJECTSupdated from path-based entries to service names:( php-fpm httpd mysqldb balena-storage )Dockerfiles
7.4.33-fpm-alpine3.16→8.3-fpm-alpineacross all arch variants and template (PHP 8.1+ required for CakePHP 5)node:20-alpine(drops end-of-life alpine 3.16)