-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
93 lines (83 loc) · 1.97 KB
/
docker-compose.yml
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
version: "3.8"
services:
zookeeper-1:
image: confluentinc/cp-zookeeper:6.1.0
networks:
- stream
environment:
ZOOKEEPER_SERVER_ID: 1
ZOOKEEPER_CLIENT_PORT: 22181
ZOOKEEPER_TICK_TIME: 2000
ZOOKEEPER_INIT_LIMIT: 5
ZOOKEEPER_SYNC_LIMIT: 2
kafka-1:
image: confluentinc/cp-kafka:6.1.0
networks:
- stream
depends_on:
- zookeeper-1
environment:
KAFKA_BROKER_ID: 1
KAFKA_ZOOKEEPER_CONNECT: zookeeper-1:22181
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://kafka-1:19092
kafka-2:
image: confluentinc/cp-kafka:6.1.0
networks:
- stream
depends_on:
- zookeeper-1
- kafka-1
environment:
KAFKA_BROKER_ID: 2
KAFKA_ZOOKEEPER_CONNECT: zookeeper-1:22181
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://kafka-2:29092
kafka-3:
image: confluentinc/cp-kafka:6.1.0
networks:
- stream
depends_on:
- zookeeper-1
- kafka-1
- kafka-2
environment:
KAFKA_BROKER_ID: 3
KAFKA_ZOOKEEPER_CONNECT: zookeeper-1:22181
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://kafka-3:39092
kafdrop:
image: obsidiandynamics/kafdrop:3.27.0
networks:
- stream
environment:
KAFKA_BROKERCONNECT: "kafka-1:19092"
JVM_OPTS: "-Xms32M -Xmx128M"
SERVER_SERVLET_CONTEXTPATH: "/"
ports:
- "9000:9000"
depends_on:
- kafka-1
- kafka-2
- kafka-3
healthcheck:
test: "curl --fail --silent http://localhost:9000/actuator/health | grep UP || exit 1"
interval: 10s
timeout: 5s
retries: 5
start_period: 40s
streamapp:
build:
context: .
dockerfile: src/main/docker/Dockerfile.jvm
depends_on:
- kafdrop
- kafka-1
- kafka-2
- kafka-3
- zookeeper-1
healthcheck:
test: "curl --fail --silent http://localhost:8080/q/health/ready | grep UP || exit 1"
networks:
- stream
ports:
- "8080:8080"
networks:
stream: