-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathdocker-compose.yml
80 lines (75 loc) · 1.72 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
version: '3'
services:
next:
container_name: next
build: ./services/next
image: next:ts
volumes:
- next:/usr/app/srcs
networks:
- my_network
env_file:
- .env
ports:
- '4242:4242'
restart: always
depends_on:
- nest
- postgresql
nest:
container_name: nest
build: ./services/nest
image: nest:ts
volumes:
- nest:/usr/app/srcs
networks:
- my_network
env_file:
- .env
ports:
- '3000:3000'
restart: always
depends_on:
- postgresql
postgresql:
container_name: postgresql
build:
context: ./services/postgresql
args:
- DB_NAME=${DB_NAME}
- POSTGRES_USER_ID=${POSTGRES_USER_ID}
- POSTGRES_USER_PASSWORD=${POSTGRES_USER_PASSWORD}
image: db:ts
expose:
- '5432'
volumes:
- db:/var/lib/postgresql/data
environment:
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
env_file:
- .env
networks:
- my_network
restart: always
volumes:
next:
driver: local
driver_opts:
type: none
o: bind
device: '${PWD}/srcs/next'
nest:
driver: local
driver_opts:
type: none
o: bind
device: '${PWD}/srcs/nest'
db:
driver: local
driver_opts:
type: none
o: bind
device: '${PWD}/srcs/postgresql'
networks:
my_network:
driver: bridge