-
Notifications
You must be signed in to change notification settings - Fork 0
/
compose.yaml
51 lines (39 loc) · 1.01 KB
/
compose.yaml
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
services:
mongodb:
image: "mongo"
volumes:
- ts-docker-db:/data/db
# environment:
# - MONGO_INITDB_ROOT_USERNAME=ts-docker
# - MONGO_INITDB_ROOT_PASSWORD=ts-docker
env_file:
- ./docker-with-typescipt-backend/.env
ts-docker-backend-container:
build:
context: ./docker-with-typescipt-backend
dockerfile: Dockerfile
ports:
- "5000:5000"
volumes:
- ts-docker-logs:/app/logs #named volume
- ./docker-with-typescipt-backend:/app #bind mount
- /app/node_modules #anonymous volume
env_file:
- ./docker-with-typescipt-backend/.env
depends_on:
- mongodb
ts-docker-frontend-conatiner:
build:
context: ./docker-with-nextjs-frontend
dockerfile: Dockerfile
ports:
- "3000:3000"
volumes:
- ./docker-with-nextjs-frontend:/app
env_file:
- ./docker-with-nextjs-frontend/.env.local
depends_on:
- ts-docker-backend-container
volumes:
ts-docker-db:
ts-docker-logs: