-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
43 lines (41 loc) · 962 Bytes
/
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
version: '3'
services:
database: #mysql
image: mysql:latest
environment:
MYSQL_DATABASE: db
MYSQL_USER: admin
MYSQL_PASSWORD: '123123'
MYSQL_ALLOW_EMPTY_PASSWORD: 1
volumes:
- "./database:/docker-entrypoint-initdb.d" #which runs the project.sql upon container startup
- "./database/my.cnf:/etc/mysql/mysql.conf.d/mysqld.cnf"
- "./database/log:/var/log/mysql" #mount the log directory
networks:
- LampDocker
www: #apache
depends_on:
- database
image: php:8.2-apache
build: ./php_custom_lib
volumes:
- "./:/var/www/html"
ports:
- 80:80 #web
- 443:443 #web
networks:
- LampDocker
phpmyadmin:
depends_on:
- database
image: phpmyadmin/phpmyadmin
ports:
- 8001:80
environment:
- PMA_HOST=database
- PMA_PORT=3306
networks:
- LampDocker
networks:
LampDocker:
driver: bridge