Commit 0b01508d by Chavee Issariyapat

support PROJECTPATH in release.conf

parent eab61836
# a helper shell script # a helper shell script
MAKE_VERSION=1.1.4 MAKE_VERSION=1.1.5
define MAKEFUNCTIONCODE define MAKEFUNCTIONCODE
function hasChanges() { function hasChanges() {
...@@ -102,6 +102,7 @@ include release.conf ...@@ -102,6 +102,7 @@ include release.conf
IMAGE=$(REGISTRY_HOST)/$(GROUPNAME)/$(PROJECTNAME) IMAGE=$(REGISTRY_HOST)/$(GROUPNAME)/$(PROJECTNAME)
VERSION=$(shell . $(RELEASE_SUPPORT) ; getVersion) VERSION=$(shell . $(RELEASE_SUPPORT) ; getVersion)
TAG=$(shell . $(RELEASE_SUPPORT); getTag) TAG=$(shell . $(RELEASE_SUPPORT); getTag)
PROJECTPATH?=.
RELEASE_SUPPORT := $(shell dirname $(abspath $(lastword $(MAKEFILE_LIST))))/.make-function RELEASE_SUPPORT := $(shell dirname $(abspath $(lastword $(MAKEFILE_LIST))))/.make-function
export MAKEFUNCTIONCODE export MAKEFUNCTIONCODE
...@@ -143,7 +144,7 @@ post-init: ...@@ -143,7 +144,7 @@ post-init:
@rm .make-function @rm .make-function
docker-build: docker-build:
docker build -t $(IMAGE):$(VERSION) . docker build -t $(IMAGE):$(VERSION) $(PROJECTPATH)
@DOCKER_MAJOR=$(shell docker -v | sed -e 's/.*version //' -e 's/,.*//' | cut -d\. -f1) ; \ @DOCKER_MAJOR=$(shell docker -v | sed -e 's/.*version //' -e 's/,.*//' | cut -d\. -f1) ; \
DOCKER_MINOR=$(shell docker -v | sed -e 's/.*version //' -e 's/,.*//' | cut -d\. -f2) ; \ DOCKER_MINOR=$(shell docker -v | sed -e 's/.*version //' -e 's/,.*//' | cut -d\. -f2) ; \
if [ $$DOCKER_MAJOR -eq 1 ] && [ $$DOCKER_MINOR -lt 10 ] ; then \ if [ $$DOCKER_MAJOR -eq 1 ] && [ $$DOCKER_MINOR -lt 10 ] ; then \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment