-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
32 lines (24 loc) · 1017 Bytes
/
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
# This Makefile helps on building the production container image
# Container name
container_name = identifiersorg/cloud-ws-httpstatus
# Default target
all: clean container_production_push
app_structure:
@echo "<===|DEVOPS|===> [PACKAGE] Application"
@mvn clean > /dev/null
@mvn package
@mkdir -p target/app/log
@mkdir -p target/app/tmp
@cp target/httpstatus-*.jar target/app/service.jar
container_production_build: app_structure
@echo "<===|DEVOPS|===> [BUILD] Production container $(container_name)"
@docker build -t $(container_name) .
container_production_push: container_production_build
@echo "<===|DEVOPS|===> [PUBLISH]> Production container $(container_name)"
@docker push $(container_name)
dev_container_build: clean container_production_build
@echo "<===|DEVOPS|===> [DEV] Preparing local container"
clean:
@echo "<===|DEVOPS|===> [CLEAN] Cleaning the space"
@mvn clean > /dev/null
.PHONY: all clean app_structure container_production_build container_production_push dev_container_build