-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
75 lines (70 loc) · 2.06 KB
/
Copy pathdocker-compose.yml
File metadata and controls
75 lines (70 loc) · 2.06 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
services:
# ── Database ──────────────────────────────────────────
postgres:
image: postgres:16-alpine
environment:
POSTGRES_DB: facetrack
POSTGRES_USER: facetrack
POSTGRES_PASSWORD: facetrack
ports:
- "5432:5432"
volumes:
- pgdata:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U facetrack"]
interval: 10s
timeout: 5s
retries: 5
restart: unless-stopped
# ── Face Recognition Microservice (Python / InsightFace) ──
face-service:
build:
context: ./FaceService
dockerfile: Dockerfile
ports:
- "8002:8002"
environment:
APP_PORT: "8002"
LOG_LEVEL: INFO
healthcheck:
test: ["CMD", "curl", "-fsS", "http://localhost:8002/healthz"]
interval: 20s
timeout: 5s
start_period: 60s
retries: 3
restart: unless-stopped
# ── Spring Boot Backend ───────────────────────────────
backend:
build:
context: ./backend
dockerfile: Dockerfile
ports:
- "8000:8000"
environment:
POSTGRES_URL: jdbc:postgresql://postgres:5432/facetrack
POSTGRES_USER: facetrack
POSTGRES_PASSWORD: facetrack
JWT_SECRET: change-me-to-a-strong-secret-key-min16
FACE_SERVICE_URL: http://face-service:8002
FACE_MATCH_THRESHOLD: "0.45"
CORS_ORIGINS: "http://localhost:3000,http://localhost:5173"
SEED_ADMIN_EMAIL: admin@facetrack.local
SEED_ADMIN_PASSWORD: admin123
depends_on:
postgres:
condition: service_healthy
face-service:
condition: service_healthy
restart: unless-stopped
# ── React Frontend (Nginx) ───────────────────────────
frontend:
build:
context: ./Frontend
dockerfile: Dockerfile
ports:
- "3000:80"
depends_on:
- backend
restart: unless-stopped
volumes:
pgdata: