-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathdocker-compose.dev.yml
More file actions
64 lines (61 loc) · 1.65 KB
/
Copy pathdocker-compose.dev.yml
File metadata and controls
64 lines (61 loc) · 1.65 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
services:
postgres-offer-db-dev:
image: postgres:15-alpine
container_name: offer-management-db
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: offer_management
ports:
- "5432:5432"
volumes:
- postgres-data-dev:/var/lib/postgresql/data
- ./database-init:/docker-entrypoint-initdb.d
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres || exit 1"]
interval: 10s
timeout: 5s
retries: 5
start_period: 10s
restart: unless-stopped
backend-apis-dev:
build:
context: ./backend-apis
dockerfile: Dockerfile.dev
container_name: offer-management-api
depends_on:
postgres-offer-db-dev:
condition: service_healthy
ports:
- "8000:8000"
environment:
- DATABASE_URL=postgresql://postgres:postgres@postgres-offer-db-dev:5432/offer_management
- PROJECT_NAME=Offer Management Platform
- SECRET_KEY=supersecretkey123notforproduction
volumes:
- ./backend-apis/app:/app/app
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 10s
frontend-app-dev:
build:
context: ./frontend-app
dockerfile: Dockerfile.dev
container_name: frontend-app
ports:
- "3000:3000"
volumes:
- ./frontend-app:/app
- /app/node_modules
- ./frontend-app/.env:/app/.env
environment:
- VITE_API_BASE_URL=http://localhost:8000/api/v1
restart: unless-stopped
depends_on:
- backend-apis-dev
volumes:
postgres-data-dev: