This is an automated email from the ASF dual-hosted git repository.

kezhenxu94 pushed a commit to branch docker/stop-buildkit
in repository https://gitbox.apache.org/repos/asf/skywalking-cli.git

commit c6f706f7c0274cf77b069cfe5273aa5bf1c6673b
Author: kezhenxu94 <kezhenx...@apache.org>
AuthorDate: Wed Nov 17 13:35:18 2021 +0800

    Stop build kit container after finishing
---
 Makefile | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile
index 1642395..83a1447 100644
--- a/Makefile
+++ b/Makefile
@@ -139,12 +139,16 @@ check-codegen:
        fi
 
 .PHONY: docker
+docker: PUSH_OR_LOAD = --load
+docker: PLATFORMS =
 docker:
-       docker buildx create --use
-       docker buildx build $(PUSH) --platform 
linux/386,linux/amd64,linux/arm64 --build-arg VERSION=$(VERSION) . -t 
$(HUB)/$(APP_NAME):$(VERSION) -t $(HUB)/$(APP_NAME):latest
+       docker buildx create --use --driver docker-container --name 
skywalking_cli > /dev/null 2>&1 || true
+       docker buildx build $(PUSH_OR_LOAD) $(PLATFORMS) --build-arg 
VERSION=$(VERSION) . -t $(HUB)/$(APP_NAME):$(VERSION) -t 
$(HUB)/$(APP_NAME):latest
+       docker buildx rm skywalking_cli
 
 .PHONY: docker.push
-docker.push: PUSH = --push
+docker.push: PUSH_OR_LOAD = --push
+docker.push: PLATFORMS = --platform linux/386,linux/amd64,linux/arm64
 docker.push: docker
 
 .PHONY: install

Reply via email to