-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
40 lines (38 loc) · 1.11 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
version: "3.7"
services:
web-server:
build:
dockerfile: php.Dockerfile
context: .
restart: always
volumes:
- "./:/var/www/"
- "./docker/php/conf.d/error_reporting.ini:/usr/local/etc/php/conf.d/error_reporting.ini"
- "./docker/php/conf.d/xdebug.ini:/usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini"
ports:
- "8181:80"
# https://github.com/compose-spec/compose-spec/blob/master/spec.md#extra_hosts
# extra_hosts adds hostname mappings to the container network interface configuration (/etc/hosts for Linux).
# Values MUST set hostname and IP address for additional hosts in the form of HOSTNAME:IP.
extra_hosts:
- "outside:${HOST_IP}"
environment:
- HOST_IP=${HOST_IP}
mysql-server:
image: mysql:8.0.19
restart: always
environment:
MYSQL_ROOT_PASSWORD: secret
volumes:
- mysql-data:/var/lib/mysql
phpmyadmin:
image: phpmyadmin/phpmyadmin:5.0.1
restart: always
environment:
PMA_HOST: mysql-server
PMA_USER: root
PMA_PASSWORD: secret
ports:
- "5000:80"
volumes:
mysql-data: