-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
52 lines (47 loc) · 888 Bytes
/
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
version: '3.8'
services:
backend:
container_name: backend
build: ./backend
depends_on:
- db
ports:
- '3000:3000'
env_file:
- ./backend/.env
networks:
- backend-net
- db-net
restart: on-failure
frontend:
container_name: frontend
build: ./frontend
ports:
- '8080:8080'
volumes:
- './frontend/src:/app/src'
- './frontend/public:/app/public'
- './frontend/vite.config.ts:/app/vite.config.ts'
command: npm run dev
networks:
- internet
- backend-net
depends_on:
- backend
db:
container_name: database
image: postgres:15.3
env_file:
- ./backend/.env
volumes:
- 'v_database:/var/lib/postgresql/data'
ports:
- "5432:5432"
networks:
- db-net
volumes:
v_database:
networks:
internet:
backend-net:
db-net: