-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
29 lines (21 loc) · 826 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
docker_image_name ?= chat-bi
docker_image_tag ?= v1.0.0
dockerfile_path = deploy/Dockerfile
registry_prefix ?= ''
build:
docker build --build-arg USE_CHINA_MIRROR=true -f $(dockerfile_path) -t $(docker_image_name):$(docker_image_tag) .
build-nocache:
docker build --build-arg USE_CHINA_MIRROR=true --no-cache -f $(dockerfile_path) -t $(docker_image_name):$(docker_image_tag) .
run:
cd deploy && docker-compose -f docker-compose-dev.yaml up -d
down:
cd deploy && docker-compose -f docker-compose-dev.yaml down
reset:
-@git pull
-@cd deploy && docker-compose -f docker-compose-dev.yaml down
-@docker rmi ${docker_image_name}:${docker_image_tag} || true
-@$(MAKE) build
-@cd deploy && docker-compose -f docker-compose-dev.yaml up -d
ddl:
bash bin/get_db_ddl.sh
.PHONY: build build-nocache run reset ddl down-dev