VERSION = 0.1.0 ## 判断操作系统及内核架构 UNAME_S := $(shell uname -s) UNAME_M := $(shell uname -m) #ifeq ($(UNAME_S),Linux) # LDFLAGS = -extldflags "-static" #endif ## 指定镜像仓库地址: "地址:端口/项目" REPOPREFIX?=localhost:32000 ## 指定镜像tag IMAGE_TAG?=v0.0.1 ## 指定国内源 MIRROR_SOURCE?=mirrors.aliyun.com ## holmes-packages的镜像tag FETCHTAG?=latest ## base image的tag BASE_IMAGE_TAG?=latest ## license版本: "sit"/"release" LICENSE_SECRET?=sit ## 指定bin目录 BIN_DIR = $(shell pwd)/bin/ .PHONY: help help: @fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//' .PHONY: cluster-manager ai-gateway: @echo "build ai-gateway" go build -v \ -tags=jsoniter -o dist/ai-gateway gitlab.com/tensorsecurity-rd/ai-gateway/cmd #upx --lzma --best dist/ai-gateway docker build -t $(REPOPREFIX)/ai-gateway:$(IMAGE_TAG) -f ./build/Dockerfile .