From fb2dcbfd74ac4a1ede3f4619cf8cd31bf97e9656 Mon Sep 17 00:00:00 2001 From: Jan-Hendrik Boll Date: Tue, 6 Sep 2022 08:46:58 +0200 Subject: [PATCH] Fix makefile Use --config in case of a docker environment, so credentials are used during build. Move image tagging to image to make it consistent with other Makefiles, i.e. user-validator. --- Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 028964f..f4e175a 100644 --- a/Makefile +++ b/Makefile @@ -30,11 +30,15 @@ build: .PHONY: image image: - $(CONTAINER_ENGINE) build -t $(REPO):$(TAG) . +ifeq ($(CONTAINER_ENGINE), podman) + @DOCKER_BUILDKIT=1 $(CONTAINER_ENGINE) build --no-cache -t $(REPO):latest . --progress=plain +else + @DOCKER_BUILDKIT=1 $(CONTAINER_ENGINE) --config=$(DOCKER_CONF) build --no-cache -t $(REPO):latest . --progress=plain +endif + @$(CONTAINER_ENGINE) tag $(REPO):latest $(REPO):$(TAG) .PHONY: image-push image-push: - $(CONTAINER_ENGINE) tag $(REPO):$(TAG) $(REPO):latest $(CONTAINER_ENGINE) --config=$(DOCKER_CONF) push $(REPO):$(TAG) $(CONTAINER_ENGINE) --config=$(DOCKER_CONF) push $(REPO):latest