-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
100 lines (90 loc) · 2.18 KB
/
docker-compose.yml
File metadata and controls
100 lines (90 loc) · 2.18 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
89
90
91
92
93
94
95
96
97
98
99
100
services:
api: &main_app
build:
context: .
dockerfile: ./Dockerfile
image: scaledp_chat:${SCALEDP_CHAT_VERSION:-latest}
restart: always
env_file:
- .env
depends_on:
db:
condition: service_healthy
rmq:
condition: service_healthy
environment:
SCALEDP_CHAT_HOST: 0.0.0.0
SCALEDP_CHAT_DB_HOST: scaledp_chat-db
SCALEDP_CHAT_DB_PORT: 5432
SCALEDP_CHAT_DB_USER: scaledp_chat
SCALEDP_CHAT_DB_PASS: scaledp_chat
SCALEDP_CHAT_DB_BASE: scaledp_chat
SCALEDP_CHAT_RABBIT_HOST: scaledp_chat-rmq
networks:
- scaledp-network
taskiq-worker:
<<: *main_app
labels: []
command:
- taskiq
- worker
- scaledp_chat.tkq:broker
networks:
- scaledp-network
db:
image: pgvector/pgvector:pg16
hostname: scaledp_chat-db
environment:
POSTGRES_PASSWORD: "scaledp_chat"
POSTGRES_USER: "scaledp_chat"
POSTGRES_DB: "scaledp_chat"
ports:
- "5434:5432"
volumes:
- scaledp_chat-db-data:/var/lib/postgresql/data
restart: always
healthcheck:
test: pg_isready -U scaledp_chat
interval: 2s
timeout: 3s
retries: 40
networks:
- scaledp-network
migrator:
image: scaledp_chat:${SCALEDP_CHAT_VERSION:-latest}
restart: "no"
command: alembic upgrade head
environment:
SCALEDP_CHAT_DB_HOST: scaledp_chat-db
SCALEDP_CHAT_DB_PORT: 5432
SCALEDP_CHAT_DB_USER: scaledp_chat
SCALEDP_CHAT_DB_PASS: scaledp_chat
SCALEDP_CHAT_DB_BASE: scaledp_chat
depends_on:
db:
condition: service_healthy
networks:
- scaledp-network
rmq:
image: rabbitmq:3.9.16-alpine
hostname: "scaledp_chat-rmq"
restart: always
environment:
RABBITMQ_DEFAULT_USER: "guest"
RABBITMQ_DEFAULT_PASS: "guest"
RABBITMQ_DEFAULT_VHOST: "/"
ports:
- "5672:5672"
healthcheck:
test: rabbitmq-diagnostics check_running -q
interval: 3s
timeout: 3s
retries: 50
networks:
- scaledp-network
volumes:
scaledp_chat-db-data:
name: scaledp_chat-db-data
networks:
scaledp-network:
external: false