-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml.example
More file actions
44 lines (39 loc) · 966 Bytes
/
docker-compose.yml.example
File metadata and controls
44 lines (39 loc) · 966 Bytes
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
version: '3.7'
# Networks
networks:
# Internal network
internal:
driver: bridge
volumes:
docker-php-mysql_data:
driver: local
# Services
services:
# Nginx
docker-php-nginx:
image: webdevops/php-nginx-dev:8.1
container_name: docker-php-nginx
networks:
- internal
working_dir: /var/www
volumes:
- .:/var/www
ports:
- "8080:80"
environment:
- WEB_DOCUMENT_ROOT=/var/www/public
- WEB_DOCUMENT_INDEX=index.php
docker-php-mysql:
image: mysql:5.7
container_name: docker-php-mysql
networks:
- internal
volumes:
- docker-php-mysql_data:/var/lib/mysql
environment:
- MYSQL_DATABASE=database
- MYSQL_ROOT_PASSWORD=root
- MYSQL_USER=user
- MYSQL_PASSWORD=password
ports:
- "3306:3306"