forked from imarc/laravel-echo-example
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
58 lines (52 loc) · 1.3 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: '2'
services:
proxy:
image: traefik
command: --docker.domain=${DOMAIN} --logLevel=DEBUG
ports:
- "80:80"
- "443:443"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./traefik/traefik.toml:/etc/traefik/traefik.toml
- ./traefik/acme.json:/etc/traefik/acme/acme.json
www:
image: imarcagency/php-apache:2
environment:
- "APACHE_ROOT=/var/www/public"
- "DOMAIN=${DOMAIN}"
labels:
- "traefik.enable=true"
- "traefik.frontend.rule=Host:www.${DOMAIN}"
- "traefik.port=80"
volumes:
- "./:/var/www"
- "./docker-configure.sh:/usr/local/bin/docker-configure"
- "app_storage:/var/www/storage"
mysql:
image: "mariadb:10.3"
environment:
- "MYSQL_DATABASE=app"
- "MYSQL_USER=app"
- "MYSQL_PASSWORD=app"
- "MYSQL_RANDOM_ROOT_PASSWORD=yes"
volumes:
- "mysql_data:/var/lib/mysql"
redis:
image: "redis:3.2"
command: "redis-server --appendonly yes"
volumes:
- "redis_data:/data"
echo:
build: ./echo
labels:
- "traefik.enable=true"
- "traefik.frontend.rule=Host:echo.${DOMAIN}"
- "traefik.port=80"
working_dir: "/usr/src/app"
volumes:
- "./:/usr/src/app"
volumes:
app_storage:
mysql_data:
redis_data: