-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
46 lines (41 loc) · 1.06 KB
/
docker-compose.yml
File metadata and controls
46 lines (41 loc) · 1.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
# From the repository root:
# docker compose up --build
# Frontend: http://localhost:3000 API: http://localhost:8000
name: stp-scheduler
services:
backend:
build: ./backend
ports:
- "8000:8000"
environment:
DATABASE_URL: postgresql://postgres:postgres@postgres:5432/stp-scheduler
# JWT signing key — replace in production (minimum 32 characters).
AUTH_SECRET: "local-docker-dev-secret-change-before-production-use"
AUTH_USERNAME: admin
AUTH_PASSWORD: admin
depends_on:
postgres:
condition: service_healthy
frontend:
build: ./frontend
ports:
- "3000:3000"
depends_on:
- backend
postgres:
image: postgres:18
environment:
POSTGRES_DB: stp-scheduler
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
volumes:
- postgres-data:/var/lib/postgresql
ports:
- "5432:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d stp-scheduler"]
interval: 3s
timeout: 5s
retries: 10
volumes:
postgres-data: