From 71d8187fdfbf12742641331435c98f03db007e02 Mon Sep 17 00:00:00 2001 From: Evan Benshetler Date: Fri, 28 Jun 2024 13:52:45 +0200 Subject: [PATCH] Change to single-arch build, separate build and push --- Makefile | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index db8673445..08a8f826f 100644 --- a/Makefile +++ b/Makefile @@ -513,7 +513,8 @@ docker/login/internal: # Build the image image/build: - DOCKER_CONFIG=${DOCKER_CONFIG} $(DOCKER) buildx build -t $(SHORT_IMAGE_REF) . --load + DOCKER_CONFIG=${DOCKER_CONFIG} $(DOCKER) build -t $(SHORT_IMAGE_REF) . + DOCKER_CONFIG=${DOCKER_CONFIG} $(DOCKER) tag $(IMAGE_REF) $(SHORT_IMAGE_REF) @echo "New image tag: $(SHORT_IMAGE_REF). You might want to" @echo "export FLEET_MANAGER_IMAGE=$(SHORT_IMAGE_REF)" ifeq ("$(CLUSTER_TYPE)","kind") @@ -557,16 +558,11 @@ image/push/emailsender: image/build/emailsender @echo "emailsender image was pushed as $(IMAGE_REF)." .PHONY: image/push/emailsender -# Build and push the image -image/push: image/push/fleet-manager image/push/probe -.PHONY: image/push - image/push/fleet-manager: IMAGE_REF="$(external_image_registry)/$(image_repository):$(image_tag)" -image/push/fleet-manager: - DOCKER_CONFIG=${DOCKER_CONFIG} $(DOCKER) buildx build -t $(IMAGE_REF) --platform $(IMAGE_PLATFORM) --output "type=image,push=true" . +image/push/fleet-manager: image/build + DOCKER_CONFIG=${DOCKER_CONFIG} $(DOCKER) push $(IMAGE_REF) @echo - @echo "Image was pushed as $(IMAGE_REF). You might want to" - @echo "export FLEET_MANAGER_IMAGE=$(IMAGE_REF)" + @echo "Image was pushed as $(IMAGE_REF)." .PHONY: image/push/fleet-manager image/push/probe: IMAGE_REF="$(external_image_registry)/$(probe_image_repository):$(image_tag)"