Skip to content
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

create builder to use for multiarch #3924

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions Makefile
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think

kueue/Makefile

Line 362 in 780675f

kueue-viz-image: VIZ_PLATFORMS=linux/amd64

no need anymore, correct?

Copy link
Contributor

@mbobrovskyi mbobrovskyi Jan 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added it to fix an issue: #3883. However, since you're now using docker buildx create --use, that should resolve it if I understand correctly.

Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ GO_VERSION := $(shell awk '/^go /{print $$2}' go.mod|head -n1)
GIT_TAG ?= $(shell git describe --tags --dirty --always)
# Image URL to use all building/pushing image targets
PLATFORMS ?= linux/amd64,linux/arm64,linux/s390x,linux/ppc64le
CLI_PLATFORMS ?= linux/amd64,linux/arm64,darwin/amd64,darwin/arm64
VIZ_PLATFORMS ?= linux/amd64,linux/arm64,linux/s390x,linux/ppc64le
CLI_PLATFORMS ?= linux/amd64,linux/arm64,darwin/amd64,darwin/arm64
DOCKER_BUILDX_CMD ?= docker buildx
IMAGE_BUILD_CMD ?= $(DOCKER_BUILDX_CMD) build
IMAGE_BUILD_EXTRA_OPTS ?=
Expand Down Expand Up @@ -331,6 +331,12 @@ importer-image: PLATFORMS=linux/amd64
importer-image: PUSH=--load
importer-image: importer-image-build

# Install multiarch build dependencies and then create a builder instance to build the kueue-viz dashboard images
kueue-viz-image-multiarch:
docker run --privileged --rm tonistiigi/binfmt --install all
BUILDER=$(shell $(DOCKER_BUILDX_CMD) create --use)
$(MAKE) kueue-viz-image-build
$(DOCKER_BUILDX_CMD) rm $$BUILDER

# Build the kueue-viz dashboard images (frontend and backend)
.PHONY: kueue-viz-image-build
Expand Down Expand Up @@ -358,7 +364,7 @@ kueue-viz-image-push: kueue-viz-image-build
# Build a docker local us-central1-docker.pkg.dev/k8s-staging-images/kueue/kueue-viz image
.PHONY: kueue-viz-image
kueue-viz-image: VIZ_PLATFORMS=linux/amd64
kueue-viz-image: PUSH=--load
kueue-viz-image: IMAGE_BUILD_EXTRA_OPTS=--load
kueue-viz-image: kueue-viz-image-build


Expand Down