aboutsummaryrefslogtreecommitdiff
path: root/Makefile.docker
diff options
context:
space:
mode:
authorGravatar Lio李歐 <lionello@users.noreply.github.com> 2023-02-15 10:15:30 -0800
committerGravatar GitHub <noreply@github.com> 2023-02-15 13:15:30 -0500
commitad623eb0d6577355eab78bd9c0fb4755d427b0af (patch)
treec1ab320c2711dbac7c44e11b8d77b349782d057c /Makefile.docker
parent52f1c64e7d61b2ed2ab8ccd4548ccd28004bfe9e (diff)
downloadcoredns-ad623eb0d6577355eab78bd9c0fb4755d427b0af.tar.gz
coredns-ad623eb0d6577355eab78bd9c0fb4755d427b0af.tar.zst
coredns-ad623eb0d6577355eab78bd9c0fb4755d427b0af.zip
build: cp Dockerfile in docker-build target (#5925)
Signed-off-by: Lionello Lunesu <lio+git@lunesu.com>
Diffstat (limited to 'Makefile.docker')
-rw-r--r--Makefile.docker5
1 files changed, 4 insertions, 1 deletions
diff --git a/Makefile.docker b/Makefile.docker
index 4610b1c10..768fafe50 100644
--- a/Makefile.docker
+++ b/Makefile.docker
@@ -73,7 +73,6 @@ endif
mkdir build/docker/$${arch}; \
curl -L $(GITHUB)/v$(VERSION)/coredns_$(VERSION)_linux_$${arch}.tgz > build/docker/$${arch}/coredns.tgz && \
( cd build/docker/$${arch}; tar xf coredns.tgz && rm coredns.tgz ); \
- cp Dockerfile build/docker/$${arch} ; \
done
.PHONY: docker-build
@@ -83,12 +82,16 @@ ifeq ($(DOCKER),)
else
docker version
for arch in $(LINUX_ARCH); do \
+ cp Dockerfile build/docker/$${arch} ; \
DOCKER_BUILDKIT=1 docker build --platform=$${arch} -t $(DOCKER_IMAGE_NAME):$${arch}-$(VERSION) build/docker/$${arch} ;\
done
endif
.PHONY: docker-push
docker-push:
+ifeq ($(VERSION),)
+ $(error "Please specify a version use. Use VERSION=<version>")
+endif
ifeq ($(DOCKER),)
$(error "Please specify Docker registry to use. Use DOCKER=coredns for releases")
else