Skip to content

Commit 1837862

Browse files
committed
CLOUDP-323996: Fix make multiarch image
1 parent f7206b0 commit 1837862

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

Makefile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -324,8 +324,10 @@ bundle: manifests ## Generate bundle manifests and metadata, then validate gene
324324
image: ## Build the operator image
325325
$(MAKE) bin/linux/amd64/manager TARGET_OS=linux TARGET_ARCH=amd64 VERSION=$(VERSION)
326326
$(MAKE) bin/linux/arm64/manager TARGET_OS=linux TARGET_ARCH=arm64 VERSION=$(VERSION)
327-
$(CONTAINER_ENGINE) build -f fast.Dockerfile --build-arg VERSION=$(VERSION) -t $(OPERATOR_IMAGE) .
328-
$(CONTAINER_ENGINE) push $(OPERATOR_IMAGE)
327+
$(CONTAINER_ENGINE) buildx create --use --name multiarch-builder \
328+
--driver docker-container --bootstrap || echo "reusing multiarch-builder"
329+
$(CONTAINER_ENGINE) buildx build --platform linux/amd64,linux/arm64 --push \
330+
-f fast.Dockerfile --build-arg VERSION=$(VERSION) -t $(OPERATOR_IMAGE) .
329331

330332
.PHONY: bundle-build
331333
bundle-build: ## Build the bundle image.

fast.Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# TODO: Eventually replace main Dockerfile
2-
FROM golang:1.24 as certs-source
2+
FROM golang:1.24 AS certs-source
33
ARG GOTOOLCHAIN=auto
44

55
# Using rolling tag to stay on latest UBI 9
6-
FROM registry.access.redhat.com/ubi9/ubi:latest as ubi-certs
6+
FROM registry.access.redhat.com/ubi9/ubi:latest AS ubi-certs
77
FROM registry.access.redhat.com/ubi9/ubi-micro:latest
88

99
ARG TARGETOS

0 commit comments

Comments
 (0)