-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
53 lines (48 loc) · 1.19 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
version: "3.8"
services:
app:
image: jregner/nginx:1.19
env_file:
- .env
volumes:
- '.:/var/www/html'
working_dir: '/var/www/html'
depends_on:
- php
- mysql
networks:
- app
- traefik
labels:
- 'traefik.http.routers.${COMPOSE_PROJECT_NAME}.rule=Host(`${DOMAIN}`)'
- 'traefik.docker.network=docker-tools_traefik'
php:
image: alexandergaal/php:8.1-fpm-dev
user: "${USER_UID}:${GROUP_UID}"
volumes:
- '.:/var/www/html'
networks:
- app
mysql:
platform: linux/x86_64
image: mysql:8.0
env_file:
- .env
environment:
MYSQL_ROOT_PASSWORD: '${DB_PASSWORD}'
MYSQL_DATABASE: '${DB_DATABASE}'
MYSQL_USER: '${DB_USERNAME}'
MYSQL_PASSWORD: '${DB_PASSWORD}'
volumes:
- 'mysqlvolume:/var/lib/mysql'
networks:
- app
volumes:
mysqlvolume:
driver: local
networks:
traefik:
external:
name: docker-tools_traefik
app:
driver: bridge