-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
60 lines (49 loc) · 1.56 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
################################################################################
# start / stop / prepare
################################################################################
init:
npm install
################################################################################
# releases
################################################################################
# patches a version
patch:
npm run release:patch
git push
# minor up
minor:
npm run release:minor
git push
# major up
release:
npm run release
git push
################################################################################
# docker building stuff
################################################################################
# you have to know what you're doing if your using this ;)
DOCKER_VERSION=19.03.13
DOCKER_COMPOSE_VERSION=1.27.4
TAG_COMPOSE=d-${DOCKER_VERSION}-dc-${DOCKER_COMPOSE_VERSION}
REGISTRY=talentplatforms/docker-compose
VCS_URL=https://github.com/talentplatforms/docker-compose
# DO NOT OVERRIDE!
_BUILD_DATE=$(shell echo $$(date -u +'%Y-%m-%dT%H:%M:%SZ'))
_VCS_REF=$(shell echo $$(git rev-parse --verify HEAD))
_IMAGE=${REGISTRY}:${TAG_COMPOSE}
_IMAGE_LATEST=${REGISTRY}:latest
build:
docker build \
--rm \
--build-arg DOCKER_VERSION=${DOCKER_VERSION} \
--build-arg DOCKER_COMPOSE_VERSION=${DOCKER_COMPOSE_VERSION} \
--build-arg BUILD_DATE=${_BUILD_DATE} \
--build-arg VCS_URL=${VCS_URL} \
--build-arg VCS_REF=${_VCS_REF} \
--build-arg BUILDKIT_INLINE_CACHE=1 \
-t ${_IMAGE} \
-t ${_IMAGE_LATEST} \
.
push:
docker push ${_IMAGE}
docker push ${_IMAGE_LATEST}