forked from hechuan73/train_ticket
-
Notifications
You must be signed in to change notification settings - Fork 247
/
Makefile
53 lines (42 loc) · 1.16 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
# Codewisdom Train-Ticket system
Repo=codewisdom
Tag=latest
Namespace="default"
DeployArgs=""
# build image
.PHONY: build
build: clean-image package build-image
.PHONY: package
package:
@mvn clean package -Dmaven.test.skip=true
.PHONY: build-image
build-image:
@hack/build-image.sh $(Repo) $(Tag)
# push image
.PHONY: push-image
push-image:
@hack/push-image.sh $(Repo)
.PHONY: publish-image
publish-image:
@script/publish-docker-images.sh $(Repo) $(Tag)
# deploy
# DeployArgs "" : deploy train-ticket with all-in-one mysql cluster
# DeployArgs "--independent-db" : deploy train-ticket with mysql cluster each service
# DeployArgs "--with-monitoring" : deploy train-ticket with prometheus
# DeployArgs "--with-tracing" : deploy train-ticket with skywalking
# DeployArgs "--all" : deploy train-ticket with mysql cluster each service
.PHONY: deploy
deploy:
@hack/deploy/deploy.sh $(Namespace) "$(DeployArgs)"
# deploy
.PHONY: reset-deploy
reset-deploy:
@hack/deploy/reset.sh $(Namespace)
.PHONY: clean
clean:
@mvn clean
@hack/clean-image.sh $(Repo)
# clean image
.PHONY: clean-image
clean-image:
@hack/clean-image.sh $(Repo)