-
Notifications
You must be signed in to change notification settings - Fork 0
/
compose.yaml
96 lines (96 loc) · 2.58 KB
/
compose.yaml
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
94
95
96
services:
zookeeper:
image: wurstmeister/zookeeper
ports:
- "2181:2181"
kafka:
image: wurstmeister/kafka
container_name: Kafka
ports:
- "9092:9092"
environment:
KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: DOCKER_INTERNAL:PLAINTEXT,DOCKER_EXTERNAL:PLAINTEXT
KAFKA_LISTENERS: DOCKER_INTERNAL://:29092,DOCKER_EXTERNAL://:9092
KAFKA_ADVERTISED_LISTENERS: DOCKER_INTERNAL://kafka:29092,DOCKER_EXTERNAL://${DOCKER_HOST_IP:-127.0.0.1}:9092
KAFKA_INTER_BROKER_LISTENER_NAME: DOCKER_INTERNAL
KAFKA_ZOOKEEPER_CONNECT: "zookeeper:2181"
KAFKA_BROKER_ID: 1
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1
depends_on:
- zookeeper
kafdrop:
image: obsidiandynamics/kafdrop
container_name: kafdrop
restart: "no"
ports:
- "9000:9000"
environment:
KAFKA_BROKERCONNECT: "kafka:29092"
depends_on:
- "kafka"
postgres:
image: postgres
container_name: postgres
environment:
- POSTGRES_PASSWORD=postgres
- POSTGRES_USER=postgres
- POSTGRES_DB=postgres
ports:
- 5432:5432
redis:
image: redis:7.2.4
hostname: redis
container_name: redis
ports:
- 6379:6379
bot:
container_name: BOT
build:
context: ./bot
dockerfile: Dockerfile
environment:
SPRING_KAFKA_BOOTSTRAP_SERVERS: "kafka:29092"
SPRING_KAFKA_CONSUMER_GROUP_ID: "BotListener"
depends_on:
- kafka
stat:
build:
context: ./stat
dockerfile: Dockerfile
container_name: stat
environment:
SPRING_KAFKA_BOOTSTRAP_SERVERS: "kafka:29092"
SPRING_KAFKA_CONSUMER_GROUP_ID: "StatListener"
SPRING_DATASOURCE_URL: "jdbc:postgresql://postgres:5432/postgres"
SPRING_DATASOURCE_USERNAME: "postgres"
SPRING_DATASOURCE_PASSWORD: "postgres"
depends_on:
- postgres
- kafka
tgb:
build:
context: ./tgprocessor
dockerfile: Dockerfile
container_name: TGB
environment:
SPRING_KAFKA_BOOTSTRAP_SERVERS: "kafka:29092"
SPRING_KAFKA_CONSUMER_GROUP_ID: "TGBListener"
REDIS_HOST: "redis"
REDIS_PORT: "6379"
depends_on:
- kafka
- redis
user:
build:
context: ./users
dockerfile: Dockerfile
container_name: user-service
environment:
SPRING_KAFKA_BOOTSTRAP_SERVERS: "kafka:29092"
SPRING_KAFKA_CONSUMER_GROUP_ID: "UserListener"
SPRING_DATASOURCE_URL: "jdbc:postgresql://postgres:5432/postgres"
SPRING_DATASOURCE_USERNAME: "postgres"
SPRING_DATASOURCE_PASSWORD: "postgres"
depends_on:
- postgres
- kafka