-
Notifications
You must be signed in to change notification settings - Fork 52
/
Makefile
45 lines (34 loc) · 1.07 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
ROOT_DIR := $(realpath $(dir $(lastword $(MAKEFILE_LIST))))
DOCKER_DIR := $(ROOT_DIR)/docker
DOCKER_FILE := $(DOCKER_DIR)/docker-compose.yml
EXAMPLES_DIR := $(ROOT_DIR)/examples
BUILD_DIR := $(ROOT_DIR)/target
.DEFAULT_TARGET: build
.PHONY: build
build:
cd $(ROOT_DIR) && mvn install -DskipTests
.PHONY: rebuild
rebuild:
cd $(ROOT_DIR) && mvn clean install -DskipTests
.PHONY: prepare-docker
prepare-docker:
cp -R $(BUILD_DIR)/kafka-connect-zeebe-*-uber.jar $(DOCKER_DIR)/connectors/kafka-connect-zeebe.jar
.PHONY: docker
docker: prepare-docker
docker-compose -f $(DOCKER_FILE) --project-directory $(DOCKER_DIR) up -d
.PHONY: docker-wait-zeebe
docker-wait-zeebe:
while ! curl --fail -s http://localhost:9600/ready; do sleep 1; done
.PHONY: docker-wait-connect
docker-wait-connect:
while ! curl --fail -s http://localhost:8083; do sleep 1; done
.PHONY: docker-stop
docker-stop:
docker-compose -f $(DOCKER_FILE) down -v
.PHONY: clean
clean: docker-stop
cd $(ROOT_DIR) && mvn clean
.PHONY: monitor
monitor:
xdg-open "http://localhost:8080"
xdg-open "http://localhost:9021"