forked from Leg0shii/smart-documents
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
56 lines (53 loc) · 1.14 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
services:
backend:
build:
context: ./backend
dockerfile: Dockerfile
container_name: smart-documents-backend
restart: unless-stopped
ports:
- "${BACKEND_PORT}:8000"
volumes:
- ./backend:/app
environment:
- DATABASE_URL=${DATABASE_URL}
env_file:
- .env
depends_on:
db:
condition: service_healthy
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
container_name: smart-documents-frontend
restart: unless-stopped
ports:
- "${FRONTEND_PORT}:5000"
- "${LIVE_UPDATE_PORT}:35729"
depends_on:
- backend
volumes:
- ./frontend:/app
env_file:
- .env
environment:
- NODE_ENV=development
db:
image: postgres:15
restart: always
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_DB}
volumes:
- db_data:/var/lib/postgresql/data
ports:
- "5432:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 10s
timeout: 5s
retries: 5
volumes:
db_data: