-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
60 lines (53 loc) · 1.26 KB
/
Copy pathdocker-compose.yml
File metadata and controls
60 lines (53 loc) · 1.26 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
services:
mongo1:
image: mongodb/mongodb-community-server:latest
command: mongod --port 27018
container_name: database
ports:
- "27018:27018"
volumes:
- mongo1_data:/data/db
mongo2:
image: mongodb/mongodb-community-server:latest
command: mongod --port 27019
container_name: database-productservice
ports:
- "27019:27019"
volumes:
- mongo2_data:/data/db
redis:
image: redis/redis-stack:latest # Lightweight Alpine-based Redis image 7-alpine
container_name: redis_cache
restart: always # Restarts if the container crashes
ports:
- "6379:6379"
- "8001:8001"
volumes:
- redis_data:/data
command: redis-server --save 60 1 --loglevel warning
authservice:
build: ./authservice
container_name: authservice
ports:
- "1100:1100"
depends_on:
- mongo1
productservice:
build: ./productservice
container_name: productservice
ports:
- "1101:1101"
depends_on:
- mongo2
- rabbitmq
- redis
rabbitmq:
image: rabbitmq:4-management
container_name: rabbitcart
ports:
- "5672:5672"
- "15672:15672"
volumes:
mongo1_data:
mongo2_data:
redis_data: