-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.dev.yml
More file actions
64 lines (61 loc) · 1.63 KB
/
docker-compose.dev.yml
File metadata and controls
64 lines (61 loc) · 1.63 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:
image: postgres:18
restart: unless-stopped
environment:
- POSTGRES_DB=${DB_NAME:-audinary}
- POSTGRES_USER=${DB_USER:-audinary}
- POSTGRES_PASSWORD=${DB_PASSWORD:-audinary}
ports:
- "5432:5432"
volumes:
- pgdata:/var/lib/postgresql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}"]
interval: 10s
timeout: 5s
retries: 5
backend:
build:
context: .
dockerfile: Dockerfile.dev
restart: unless-stopped
depends_on:
postgres:
condition: service_healthy
ports:
- "8080:8080"
volumes:
- ./server:/var/www/html
- ./nginx.conf:/etc/nginx/conf.d/default.conf:ro
- backend_vendor:/var/www/html/vendor
environment:
- DB_HOST=postgres
- DB_NAME=${DB_NAME:-audinary}
- DB_USER=${DB_USER:-audinary}
- DB_PASSWORD=${DB_PASSWORD:-audinary}
- JWT_SECRET=${JWT_SECRET:-dev-jwt-secret-do-not-use-in-production}
command: >
sh -c "cd /var/www/html
&& composer install --no-interaction
&& php scripts/run_migrations.php
&& exec /usr/bin/supervisord -c /etc/supervisor/conf.d/supervisord.conf"
frontend:
image: node:25-alpine
restart: unless-stopped
working_dir: /app
depends_on:
- backend
ports:
- "3000:3000"
volumes:
- ./client:/app
- frontend_node_modules:/app/node_modules
environment:
- API_URL=http://backend:8080
- WS_URL=ws://backend:8080
command: sh -c "npm install && npm run dev"
volumes:
pgdata:
backend_vendor:
frontend_node_modules: