-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
52 lines (48 loc) · 1.16 KB
/
docker-compose.yml
File metadata and controls
52 lines (48 loc) · 1.16 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
version: '3.8'
services:
postgres:
image: postgres:16-alpine
container_name: unified-postgres
environment:
POSTGRES_USER: taskapp
POSTGRES_PASSWORD: taskapp_secret
POSTGRES_DB: taskapp
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U taskapp -d taskapp"]
interval: 5s
timeout: 5s
retries: 5
backend:
build:
context: ./backend
dockerfile: Dockerfile
container_name: unified-backend
environment:
PORT: 4000
DATABASE_URL: postgresql://taskapp:taskapp_secret@postgres:5432/taskapp?schema=public
JWT_SECRET: dev-jwt-secret-change-in-production
JWT_EXPIRES_IN: 7d
CORS_ORIGIN: http://localhost:3000
NODE_ENV: development
ports:
- "4000:4000"
depends_on:
postgres:
condition: service_healthy
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
container_name: unified-frontend
environment:
VITE_API_URL: http://localhost:4000
ports:
- "3000:3000"
depends_on:
- backend
volumes:
postgres_data: