-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
60 lines (57 loc) · 1.04 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
58
59
60
version: "3"
networks:
app-networks:
driver: bridge
volumes:
dbdata:
services:
# PHP Service
app:
build:
context: ./
dockerfile: app.dockerfile
container_name: webapp
working_dir: /var/www
volumes:
- ./src:/var/www
environment:
- "DB_PORT=3306"
- "DB_HOST=database"
networks:
- app-networks
# NGINX Service
web:
build:
context: ./
dockerfile: web.dockerfile
container_name: webserver
working_dir: /var/www
volumes:
- ./src:/var/www
ports:
- 8000:80
networks:
- app-networks
# MARIADB Service
database:
image: mysql:5.7
container_name: db
volumes:
- dbdata:/var/lib/mysql
environment:
- "MYSQL_DATABASE=coba"
- "MYSQL_ROOT_PASSWORD=admin123"
ports:
- "3306:3306"
networks:
- app-networks
# PHPMyAdmin Service
dbpanel:
image: phpmyadmin/phpmyadmin
container_name: db_panel
ports:
- 4000:80
depends_on:
- database
networks:
- app-networks