-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
93 lines (83 loc) · 1.72 KB
/
docker-compose.yml
File metadata and controls
93 lines (83 loc) · 1.72 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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
services:
app:
build:
context: ./docker/php
volumes:
- .:/var/www
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_started
networks:
- internal
nginx:
image: nginx:alpine
ports:
- "8000:80"
volumes:
- .:/var/www
- ./docker/nginx/default.conf:/etc/nginx/conf.d/default.conf
depends_on:
- app
networks:
- internal
frontend:
image: node:20-alpine
working_dir: /var/www
volumes:
- .:/var/www
command: sh -c "npm install && npm run dev"
ports:
- "5173:5173"
networks:
- internal
postgres:
image: postgres:15-alpine
restart: unless-stopped
environment:
POSTGRES_DB: gameboxd
POSTGRES_USER: gameboxd
POSTGRES_PASSWORD: secret
volumes:
- pgdata:/var/lib/postgresql/data
networks:
- internal
healthcheck:
test: ["CMD-SHELL", "pg_isready -U gameboxd"]
interval: 5s
timeout: 5s
retries: 5
redis:
image: redis:alpine
networks:
- internal
queue:
build:
context: ./docker/php
command: php artisan queue:work --sleep=3 --tries=3 --timeout=90
volumes:
- .:/var/www
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_started
networks:
- internal
scheduler:
build:
context: ./docker/php
command: sh -c "while true; do php artisan schedule:run --verbose --no-interaction; sleep 60; done"
volumes:
- .:/var/www
depends_on:
postgres:
condition: service_healthy
networks:
- internal
volumes:
pgdata:
networks:
internal:
driver: bridge