-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
87 lines (82 loc) · 1.52 KB
/
docker-compose.yml
File metadata and controls
87 lines (82 loc) · 1.52 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
version: '3.8'
services:
#mongodb
# mongo-db:
# image: mongo:latest
# container_name: mongodb
# ports:
# - "27017:27017"
# networks:
# - app-network
# volumes:
# - ./db/:/data/db
#customer
customer:
build:
context: ./customer
dockerfile: Dockerfile
container_name: customer
ports:
- "3000:3000"
restart: always
# depends_on:
# - mongo-db
networks:
- app-network
env_file:
- ./customer/.env
volumes:
- .:/app/
- /app/customer/node_modules
#products
products:
build:
context: ./products
dockerfile: Dockerfile
container_name: products
ports:
- "3001:3001"
restart: always
# depends_on:
# - mongo-db
networks:
- app-network
env_file:
- ./products/.env
volumes:
- .:/app
- /app/products/node_modules
#shopping
shopping:
build:
context: ./products
dockerfile: Dockerfile
container_name: shopping
ports:
- "3002:3002"
restart: always
# depends_on:
# - mongo-db
networks:
- app-network
env_file:
- ./shopping/.env
volumes:
- .:/app
- /app/shopping/node_modules
#NGINX reverse proxy service
nginx-proxy:
build:
dockerfile: Dockerfile
context: ./proxy
depends_on:
- customer
- products
- shopping
ports:
- 80:80
networks:
- app-network
networks:
app-network: # Define the network
driver: bridge