-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
88 lines (81 loc) · 1.69 KB
/
docker-compose.yaml
File metadata and controls
88 lines (81 loc) · 1.69 KB
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
services:
users_app:
build:
context: .
target: dev
container_name: users-app
volumes:
- .:/proj/backend
depends_on:
kafka:
condition: service_healthy
ports:
- "127.0.0.1:8000:8000"
networks:
- dev-backend-net
# analytics_app:
# build: .
# container_name: kafka-consumer
# command: [ "python", "-m", "kafka.api_app.analytics.consumer" ]
# depends_on:
# kafka:
# condition: service_healthy
# networks:
# - kafka-net
db:
container_name: dev-db-postgres
image: postgres:16.9-alpine
restart: always
hostname: postgres
networks:
- dev-backend-net
env_file:
- .env
ports:
- '127.0.0.1:5432:5432'
healthcheck:
test: [ "CMD-SHELL", "pg_isready -U postgres -d postgres" ]
interval: 10s
timeout: 3s
retries: 3
zookeeper:
image: confluentinc/cp-zookeeper:7.4.0
container_name: zookeeper
env_file:
- .env
ports:
- "2181:2181"
networks:
- dev-backend-net
kafka:
image: confluentinc/cp-kafka:7.4.0
container_name: kafka
depends_on:
- zookeeper
ports:
- "9092:9092"
env_file:
- .env
networks:
- dev-backend-net
restart: always
healthcheck:
test: [ "CMD", "kafka-topics", "--bootstrap-server", "localhost:9092", "--list" ]
interval: 10s
timeout: 10s
retries: 10
start_period: 40s
kafka-ui:
image: provectuslabs/kafka-ui:latest
container_name: kafka-ui
depends_on:
- kafka
ports:
- "8080:8080"
env_file:
- .env
networks:
- dev-backend-net
networks:
dev-backend-net:
driver: bridge