-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
executable file
·50 lines (45 loc) · 1.03 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
version: "3.5"
services:
apache:
build:
context: ./
target: base
container_name: app_apache
restart: always
volumes:
- ./:/var/www/html
depends_on:
- database
ports:
- "5000:80"
database:
image: mysql:8.0
container_name: app_db
command: --sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION' --default-authentication-plugin=mysql_native_password
volumes:
- db_data:/var/lib/mysql
restart: always
environment:
- MYSQL_ROOT_PASSWORD=123
- MYSQL_CONNECTION=mysql
- MYSQL_HOST=mysql
- MYSQL_PORT=3306
- MYSQL_DATABASE=fruit
- MYSQL_USERNAME=root
ports:
- "5307:3306"
phpmyadmin:
image: phpmyadmin/phpmyadmin
container_name: app_phpmyadmin
environment:
- PMA_HOST=app_db
restart: always
ports:
- 5001:80
mail:
image: mailhog/mailhog
container_name: mail_hog
ports:
- 8025:8025
volumes:
db_data: