-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.yml
67 lines (63 loc) · 1.42 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
version: '3.8'
services:
main-service:
build:
context: .
dockerfile: Dockerfile
ports:
- "3000:3000"
env_file: .env
environment:
- NODE_ENV=production
- PORT=3000
- MONGO_URI=${MONGO_URI}
- RABBITMQ_URL=${RABBITMQ_URL}
- RABBITMQ_QUEUE=${RABBITMQ_QUEUE}
healthcheck:
test: ["CMD", "bun", "run", "healthcheck"]
interval: 30s
timeout: 10s
retries: 3
depends_on:
- rabbitmq
- mongodb
video-processing-service:
build:
context: ./video-processing-service
dockerfile: Dockerfile
ports:
- "3001:3001"
env_file: .env
environment:
- NODE_ENV=production
- PORT=3001
- MONGO_URI=${MONGO_URI}
- RABBITMQ_URL=${RABBITMQ_URL}
- RABBITMQ_QUEUE=${RABBITMQ_QUEUE}
healthcheck:
test: ["CMD", "bun", "run", "healthcheck"]
interval: 30s
timeout: 10s
retries: 3
depends_on:
- rabbitmq
- mongodb
rabbitmq:
image: "rabbitmq:3-management"
ports:
- "5672:5672"
- "15672:15672"
healthcheck:
test: ["CMD", "rabbitmq-diagnostics", "check_port_connectivity"]
interval: 30s
timeout: 10s
retries: 3
mongodb:
image: "mongo:4.2"
ports:
- "27017:27017"
healthcheck:
test: ["CMD", "mongosh", "--eval", "db.adminCommand('ping')"]
interval: 30s
timeout: 10s
retries: 3