-
-
Notifications
You must be signed in to change notification settings - Fork 65
/
Makefile
47 lines (36 loc) · 1.51 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
##################################################################
# Project Convenience Makefile Wrapper for Maven & Docker #
##################################################################
# This makefile is just a convenience wrapper for the Maven
# program and the docker build which is used to build packaged
# microservices for entire functionality. The actual building
# rules for this project may be found in the Maven "pom.xml"
# */Dockerfile and file located in this folder.
######################### DEFINITIONS ############################
# Define the commandline invocation of Maven if necessary:
# ifeq ($(MVN))
# MVN := mvn
# endif
MVN = mvn
DOCKER_COMPOSE=docker-compose
######################## BUILD TARGETS ###########################
clean:
cd ./TrashEmailService && $(MVN) clean
cd ./EmailsToTelegramService && $(MVN) clean
build :
echo "Building TrashEmailService ...\n"
cd ./TrashEmailService && $(MVN) -Dmaven.test.skip=true install
echo "Building EmailsToTelegramService ...\n"
cd ./EmailsToTelegramService && $(MVN) -Dmaven.test.skip=true install
echo "Building the docker-compose ...\n"
$(DOCKER_COMPOSE) build
copy :
echo $(ENV)
cp ./EmailsToTelegramServiceConfig-$(ENV).yml EmailsToTelegramService/src/main/resources/application-$(ENV).yml
cp ./TrashEmailServiceConfig-$(ENV).yml TrashEmailService/src/main/resources/application-$(ENV).yml
qa : export ENV:=qa
qa : clean copy build
dev : export ENV:=dev
dev : clean copy build
prod : export ENV:=prod
prod : clean copy build