-
Notifications
You must be signed in to change notification settings - Fork 0
Add support for arm64 images #83
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -10,12 +10,24 @@ on: | |||||||
| permissions: {} | ||||||||
|
|
||||||||
| env: | ||||||||
| REGISTRY: ghcr.io/${{ github.repository }} | ||||||||
| TAG: smoke-test | ||||||||
| REGISTRY: 127.0.0.1:5000/qubesome | ||||||||
| TAG: latest | ||||||||
|
|
||||||||
| jobs: | ||||||||
| build-images: | ||||||||
| runs-on: ubuntu-latest | ||||||||
| strategy: | ||||||||
| fail-fast: false | ||||||||
| matrix: | ||||||||
| platform: [ubuntu-latest, ubuntu-24.04-arm] | ||||||||
|
|
||||||||
| runs-on: ${{ matrix.platform }} | ||||||||
|
|
||||||||
| services: | ||||||||
| registry: | ||||||||
| image: registry:3 | ||||||||
| ports: | ||||||||
| - 5000:5000 | ||||||||
|
|
||||||||
| steps: | ||||||||
| - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | ||||||||
| with: | ||||||||
|
|
@@ -26,10 +38,13 @@ jobs: | |||||||
|
|
||||||||
| - name: Setup Docker Buildx | ||||||||
| uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 | ||||||||
| with: | ||||||||
| name: qubesome | ||||||||
| driver-opts: network=host | ||||||||
| platforms: linux/amd64,linux/arm64 | ||||||||
|
|
||||||||
|
Comment on lines
39
to
45
|
||||||||
| - name: Setup Docker Buildx | |
| uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 | |
Copilot
AI
Jan 19, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both matrix jobs (amd64 and arm64 runners) build and push images for both platforms (linux/amd64,linux/arm64), which means the same multi-platform images are built and pushed twice. This is redundant and wastes CI resources. Consider either having each runner build only for its native platform, or having only one runner build the multi-platform images. If the intent is to test that the build process works on both runner architectures, this should be documented.
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -1,33 +1,48 @@ | ||||||||||||
| REGISTRY ?= workload-images | ||||||||||||
| TAG ?= latest | ||||||||||||
|
|
||||||||||||
| BUILDER ?= docker | ||||||||||||
| RUNNER ?= docker | ||||||||||||
| BUILDER ?= docker buildx | ||||||||||||
|
|
||||||||||||
| WORKLOADS=$(shell find workloads -mindepth 2 -maxdepth 2 -type f -name 'Dockerfile' | sort -u | cut -f 2 -d'/') | ||||||||||||
| TOOLS=$(shell find tools -mindepth 2 -maxdepth 2 -type f -name 'Dockerfile' | sort -u | cut -f 2 -d'/') | ||||||||||||
|
|
||||||||||||
| build: | ||||||||||||
| MACHINE = qubesome | ||||||||||||
|
|
||||||||||||
| # ACTION can only be --load when TARGET_PLATFORM is the current platform: | ||||||||||||
| # TARGET_PLATFORMS=linux/amd64 ACTION=--load make build-workload-xorg | ||||||||||||
| ACTION ?= --load | ||||||||||||
| TARGET_PLATFORMS ?= $(shell docker info --format '{{.ClientInfo.Os}}/{{.ClientInfo.Arch}}') | ||||||||||||
| SUPPORTED_PLATFORMS = linux/amd64,linux/arm64 | ||||||||||||
pjbgf marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||||||||
|
|
||||||||||||
| build: build-workload-base | ||||||||||||
pjbgf marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||||||||
| $(MAKE) $(addprefix build-workload-, $(WORKLOADS)) | ||||||||||||
| $(MAKE) $(addprefix build-tool-, $(TOOLS)) | ||||||||||||
|
|
||||||||||||
| build-workload-%: | ||||||||||||
| buildx-machine: | ||||||||||||
| $(BUILDER) use $(MACHINE) >/dev/null 2>&1 || \ | ||||||||||||
| $(BUILDER) create --name=$(MACHINE) --driver-opt network=host --platform=$(SUPPORTED_PLATFORMS) | ||||||||||||
|
|
||||||||||||
|
Comment on lines
+26
to
+28
|
||||||||||||
| $(BUILDER) use $(MACHINE) >/dev/null 2>&1 || \ | |
| $(BUILDER) create --name=$(MACHINE) --driver-opt network=host --platform=$(SUPPORTED_PLATFORMS) | |
| $(BUILDER) inspect $(MACHINE) >/dev/null 2>&1 || \ | |
| $(BUILDER) create --name=$(MACHINE) --driver-opt network=host --platform=$(SUPPORTED_PLATFORMS) >/dev/null 2>&1 | |
| $(BUILDER) use $(MACHINE) >/dev/null 2>&1 |
pjbgf marked this conversation as resolved.
Show resolved
Hide resolved
Copilot
AI
Jan 19, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The target substitution uses the wrong separator. This line should use the colon separator to match the pattern variable, not a forward slash. The correct syntax should be build-workload-$* (not build-workload-$(subst :,/,$*)) since the subst operation is already done by the pattern matching.
| $(MAKE) build-workload-$(subst :,/,$*) | |
| $(MAKE) build-workload-$* |
Uh oh!
There was an error while loading. Please reload this page.