-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
89 lines (84 loc) · 2.01 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
version: '3'
services:
guardian:
image: guardian:latest
build:
context: .
dockerfile: Dockerfile
environment:
- REDIS_ADDR=redis:6379
- MONGODB_URI=mongodb://mongodb:27017
- RABBITMQ_URI=amqp://rabbitmq:5672
- MILVUS_URI=milvus:19530
- SERVER_PORT=8080
- FAILURE_THRESHOLD=3
- CB_TIMEOUT=5
- LOCK_TIME=5
- APP_ENV=production
- JWT_SECRET_KEY=${JWT_SECRET_KEY}
- ACTIVATION_SECRET_KEY=${ACTIVATION_SECRET_KEY}
volumes:
- ./.env.yaml:/app/.env.yaml
ports:
- "8080:8080"
depends_on:
redis:
condition: service_healthy
# rabbitmq:
# condition: service_healthy
mongodb:
condition: service_started
# milvus:
# condition: service_healthy
network_mode: host
redis:
image: redis:latest
container_name: redis_db
restart: unless-stopped
ports:
- "6379:6379"
volumes:
- /data/cache:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 5
network_mode: host
# rabbitmq:
# image: rabbitmq:3-management
# container_name: rabbitmq
# restart: unless-stopped
# ports:
# - "5672:5672"
# - "15672:15672" # RabbitMQ management UI
# healthcheck:
# test: ["CMD", "rabbitmqctl", "status"]
# interval: 10s
# timeout: 5s
# retries: 5
mongodb:
image: mongo:latest
container_name: mongodb
restart: unless-stopped
ports:
- "27017:27017"
volumes:
- /data/mongodb:/data/db
healthcheck:
test: ["CMD", "mongodb", "--eval", "db.adminCommand('ping')"]
interval: 10s
timeout: 5s
retries: 5
network_mode: host
# milvus:
# image: milvusdb/milvus:latest
# container_name: milvus
# restart: unless-stopped
# ports:
# - "19530:19530" # Milvus main service port
# healthcheck:
# test: ["CMD", "curl", "-f", "http://milvus:19530"]
# interval: 10s
# timeout: 5s
# retries: 5