diff --git a/Makefile b/Makefile index c21ce7a..d085dee 100644 --- a/Makefile +++ b/Makefile @@ -9,12 +9,12 @@ image_name :=colovu/openldap REGISTRY_URL :=docker.colovu.com # 定义系统默认使用的源服务器,包含:default / ustc / aliyun -APT_SOURCE :=ustc +APT_SOURCE :=aliyun # 定义镜像TAG,类似: -# <镜像名>:<分支名>-<7位Git ID> # Git 仓库且无文件修改直接编译 -# <镜像名>:<分支名>-<年月日>-<时分秒> # Git 仓库有文件修改后的编译 -# <镜像名>:latest-<年月日>-<时分秒> # 非 Git 仓库编译 +# <镜像名>:<分支名>-<7位Git ID> # Git 仓库且无文件修改直接编译 +# <镜像名>:<分支名>-<年月日>-<时分秒> # Git 仓库有文件修改后的编译 +# <镜像名>:latest-<年月日>-<时分秒> # 非 Git 仓库编译 current_subversion:=$(shell if [ ! `git status >/dev/null 2>&1` ]; then git rev-parse --short HEAD; else date +%y%m%d-%H%M%S; fi) image_tag:=$(shell if [ ! `git status >/dev/null 2>&1` ]; then git rev-parse --abbrev-ref HEAD | sed -e 's/master/latest/'; else echo "latest"; fi)-$(current_subversion) @@ -27,9 +27,6 @@ build-arg+=--build-arg LOCAL_URL=http://$(local_ip)/dist-files .PHONY: build clean clearclean upgrade -# 屏蔽 "Use 'docker scan' to run Snyk tests against images to find vulnerabilities and learn how to fix them" -export DOCKER_SCAN_SUGGEST=false - build: @echo "Build $(image_name):$(image_tag)" @docker build --progress plain --force-rm $(build-arg) -t $(image_name):$(image_tag) .