Skip to content

Commit

Permalink
Makefile: Drop unneeded TEMPDIR
Browse files Browse the repository at this point in the history
Builds in docker now, so tempdir is not needed and we'll provide GOARCH
to Docker as a build-arg

Signed-off-by: Manuel Rüger <[email protected]>
  • Loading branch information
mrueg committed Jul 22, 2020
1 parent f2cd3e7 commit 0be9f6e
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,6 @@ test-benchmark-compare: $(BENCHCMP_BINARY)
./tests/compare_benchmarks.sh master
./tests/compare_benchmarks.sh ${LATEST_RELEASE_BRANCH}

TEMP_DIR := $(shell mktemp -d)

all: all-container

sub-container-%:
Expand All @@ -94,11 +92,9 @@ all-container: $(addprefix sub-container-,$(ALL_ARCH))
all-push: $(addprefix sub-push-,$(ALL_ARCH))

container: .container-$(ARCH)
.container-$(ARCH): kube-state-metrics
cp -r * "${TEMP_DIR}"
${DOCKER_CLI} build -t $(MULTI_ARCH_IMG):$(TAG) "${TEMP_DIR}"
.container-$(ARCH):
${DOCKER_CLI} build -t $(MULTI_ARCH_IMG):$(TAG) --build-arg GOARCH=$(ARCH) .
${DOCKER_CLI} tag $(MULTI_ARCH_IMG):$(TAG) $(MULTI_ARCH_IMG):latest
rm -rf "${TEMP_DIR}"

ifeq ($(ARCH), amd64)
# Adding check for amd64
Expand Down

0 comments on commit 0be9f6e

Please sign in to comment.