From 2279245b8cea53ce243e1fdf538ccd41beed5480 Mon Sep 17 00:00:00 2001 From: James Mills Date: Fri, 17 Sep 2021 07:49:07 +1000 Subject: [PATCH] Update image target --- .gitignore | 1 + Makefile | 8 +++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index a900039..3feab3e 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,7 @@ /tmp /dist +/cacheDb /coverage.txt /bitcask diff --git a/Makefile b/Makefile index ed48863..6f58af0 100644 --- a/Makefile +++ b/Makefile @@ -27,8 +27,14 @@ install: build @go install ./cmd/bitcask/... @go install ./cmd/bitcaskd/... +ifeq ($(PUBLISH), 1) image: - @docker build -t prologic/bitcask . + @docker build --build-arg VERSION="$(VERSION)" --build-arg COMMIT="$(COMMIT)" -t prologic/bitcask . + @docker push prologic/bitcask +else +image: + @docker build --build-arg VERSION="$(VERSION)" --build-arg COMMIT="$(COMMIT)" -t prologic/bitcask . +endif release: @./tools/release.sh