From ecc4f3b6d6f0f3efc0c954f794a5153d26a5ae83 Mon Sep 17 00:00:00 2001 From: Alexander Block Date: Mon, 8 Jul 2024 22:24:35 +0200 Subject: [PATCH] ci: Split build target into two steps --- .github/workflows/tests.yml | 2 +- Makefile | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 3b20dc4..142accd 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -98,7 +98,7 @@ jobs: uses: docker/setup-buildx-action@v3 - name: Build template-controller run: | - GOARCH=${{ matrix.goarch }} make build + GOARCH=${{ matrix.goarch }} make build-bin - name: Build docker images run: | docker build -t test-image --platform=${{ matrix.docker_platform }} . diff --git a/Makefile b/Makefile index e2cd290..e87799f 100644 --- a/Makefile +++ b/Makefile @@ -61,7 +61,10 @@ test: manifests generate fmt vet envtest ## Run tests. ##@ Build .PHONY: build -build: generate fmt vet ## Build manager binary. +build: generate fmt vet build-bin ## Build manager binary. + +.PHONY: build-bin +build-bin: ## Build manager binary. go build -o bin/manager main.go .PHONY: run