forked from iurygdeoliveira/Estudos_de_PHP
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
executable file
·43 lines (42 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
version: "3"
services:
mysql:
image: mysql:latest
environment:
- MYSQL_USER=root
- MYSQL_ROOT_PASSWORD=root
- MYSQL_DATABASE=LP1
ports:
- 3306:3306
volumes:
- ./docker/mysql/:/var/lib/mysql
networks:
- rede_docker
php:
build: ./docker/php
volumes:
- ./www:/usr/share/nginx/html
- ./docker/php/php.ini:/usr/local/etc/php/php.ini
depends_on:
- mysql
environment:
- MYSQL_USER=root
- MYSQL_PASSWORD=root
- MYSQL_DATABASE=LP1
- MYSQL_HOST=mysql
networks:
- rede_docker
nginx:
image: "nginx:latest"
volumes:
- ./www:/usr/share/nginx/html
- ./docker/nginx/default.conf:/etc/nginx/conf.d/default.conf
ports:
- "9999:80"
depends_on:
- "php"
networks:
- rede_docker
networks:
rede_docker:
driver: bridge