forked from deworkerpro/demo-php-app-speedup
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
58 lines (54 loc) · 1.65 KB
/
docker-compose.yml
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
version: "3.9"
services:
traefik:
image: traefik:2.11
command:
--providers.docker=true
--providers.docker.exposedByDefault=false
--entryPoints.http.address=:80
ports:
- "80:80"
networks:
- traefik-public
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
labels:
- traefik.enable=true
- traefik.docker.network=traefik-public
app:
build:
context: app/docker
dockerfile: development/php/Dockerfile
environment:
APP_ENV: dev
APP_SECRET: secret
DATABASE_URL: sqlite:////app/data/database.sqlite
volumes:
- ./app:/app
networks:
- traefik-public
- default
command: sh -c "until [ -f .ready ] ; do sleep 1 ; done && rr serve -c .rr.dev.yaml --debug"
labels:
- traefik.enable=true
- traefik.docker.network=traefik-public
- traefik.http.routers.app.rule=Host(`localhost`)
- traefik.http.routers.app.entryPoints=http
- traefik.http.services.app.loadBalancer.server.port=80
app-php-cli:
build:
context: app/docker
dockerfile: development/php-cli/Dockerfile
environment:
APP_ENV: dev
APP_SECRET: secret
DATABASE_URL: sqlite:////app/data/database.sqlite
volumes:
- ./app:/app
benchmark:
build:
context: benchmark
network_mode: service:traefik
networks:
traefik-public:
name: traefik-public