-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
57 lines (53 loc) · 1.51 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
services:
php:
build:
context: .
dockerfile: .dev/docker/php/Dockerfile
container_name: php
environment:
- XDEBUG_MODE=${SAIL_XDEBUG_MODE:-off}
- XDEBUG_CONFIG=${SAIL_XDEBUG_CONFIG:-client_host=host.docker.internal}
ports:
- 9000:9000
- 5173:5173
volumes:
- .:/var/www/html
- .dev/docker/php/settings/php.ini:/usr/local/etc/php/php.ini
- ~/.gitconfig:/root/.gitconfig:ro
networks:
- application
depends_on:
- database
database:
image: mysql:8.0
container_name: database
environment:
MYSQL_ROOT_PASSWORD: ${DB_PASSWORD}
MYSQL_DATABASE: ${DB_DATABASE}
MYSQL_PASSWORD: ${DB_PASSWORD}
ports:
- 3306:3306
volumes:
- mysql:/var/lib/mysql
- .dev/mysql/init-database.sql:/docker-entrypoint-initdb.d/init-database.sql
networks:
- application
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
interval: 30s
timeout: 10s
retries: 3
phpmyadmin:
image: phpmyadmin/phpmyadmin
container_name: phpmyadmin
environment:
PMA_HOST: database
MYSQL_ROOT_PASSWORD: ${DB_PASSWORD}
ports:
- 8080:80
networks:
- application
networks:
application:
volumes:
mysql: