Merge pull request #8019 from zhasm/feature/make-with-arch

make with ARCH argument
This commit is contained in:
yunion-ci-robot
2020-09-23 16:39:17 +08:00
committed by GitHub
2 changed files with 6 additions and 1 deletions
+1 -1
View File
@@ -314,7 +314,7 @@ VERSION ?= $(shell git describe --exact-match 2> /dev/null || \
git describe --match=$(git rev-parse --short=8 HEAD) --always --dirty --abbrev=8)
image:
TAG=$(VERSION) REGISTRY=$(REGISTRY) $(ROOT_DIR)/scripts/docker_push.sh $(filter-out $@,$(MAKECMDGOALS))
DEBUG=$(DEBUG) ARCH=$(ARCH) TAG=$(VERSION) REGISTRY=$(REGISTRY) $(ROOT_DIR)/scripts/docker_push.sh $(filter-out $@,$(MAKECMDGOALS))
.PHONY: image
+5
View File
@@ -3,6 +3,10 @@
set -o errexit
set -o pipefail
if [ "$DEBUG" == "true" ]; then
set -ex ;export PS4='+(${BASH_SOURCE}:${LINENO}): ${FUNCNAME[0]:+${FUNCNAME[0]}(): }'
fi
readlink_mac() {
cd `dirname $1`
TARGET_FILE=`basename $1`
@@ -83,6 +87,7 @@ buildx_and_push() {
local path=$3
local arch=$4
docker buildx build -t "$tag" --platform "linux/$arch" -f "$2" "$3" --push
docker pull "$tag"
}
push_image() {