-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.test-kafka.yml
53 lines (49 loc) · 1.25 KB
/
docker-compose.test-kafka.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
version: '2.4'
services:
# Overrides for docker-compose.test.yml
kafka:
image: &redpanda vectorized/redpanda:v22.3.10@sha256:dc1f47dcc592857ea7831e2a28829ebca95a9cd350d6e6374a98414866b62c6f
entrypoint:
- /usr/bin/rpk
- redpanda
- start
- --overprovisioned
- --smp=1
- --memory=1G
- --reserve-memory=0M
- --check=false
- --node-id=0
- --kafka-addr=PLAINTEXT://kafka:9092
- --advertise-kafka-addr=PLAINTEXT://kafka:9092
- --default-log-level=warn
- --logger-log-level=storage=info
kafka-topic-client:
image: *redpanda
links:
- kafka
entrypoint:
- /bin/bash
- -cex
- |
until rpk cluster --brokers kafka:9092 info; do sleep 1; done;
rpk topic --brokers kafka:9092 create $$TOPIC_NAME
environment:
TOPIC_NAME: &topicname "minio-events"
minio0:
links:
- kafka
depends_on:
- kafka-topic-client
environment:
MINIO_NOTIFY_KAFKA_ENABLE: "on"
MINIO_NOTIFY_KAFKA_BROKERS: &bootstrap kafka:9092
MINIO_NOTIFY_KAFKA_TOPIC: *topicname
app0:
depends_on:
- minio0
- kafka
environment:
KAFKA_BOOTSTRAP: *bootstrap
KAFKA_TOPIC: *topicname
KAFKA_CONSUMER_GROUP: "app0"
KAFKA_FETCH_MAX_WAIT: 500ms