-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
89 lines (87 loc) · 1.93 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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
version: '2.1'
services:
# web server
nginx:
image: nginx:latest
ports:
- "80:80"
- "443:443"
volumes:
# app
- ./app/src:/usr/share/nginx/html
# nginx configs
- ./nginx/nginx.conf:/etc/nginx/nginx.conf:ro
- ./nginx/conf.d/:/etc/nginx/conf.d/:ro
# certificates
- ./nginx/ca/server.crt/:/etc/nginx/server.crt:ro
- ./nginx/ca/server.key/:/etc/nginx/server.key:ro
environment:
- APPLICATION_ENV=development
- IPV4_NETWORK=172.18.0
links:
- fpm:__DOCKER_PHP_FPM__
networks:
nibiru-network:
aliases:
- nginx
# php-fpm
fpm:
build: ./php-fpm
ports:
- "9000"
volumes:
- ./app/src:/usr/share/nginx/html
# Your php.ini
- ./php-fpm/php.ini-production:/usr/local/etc/php/php.ini:ro
links:
- mysql:mysql
environment:
- DB_HOST=mysql
- DB_DATABASE=nibiru
- DB_USERNAME=nibiru
- DB_PASSWORD=mypassword
- IPV4_NETWORK=172.18.0
networks:
nibiru-network:
aliases:
- fpm
# database
mysql:
image: mysql:5.7.22
ports:
# Allow client to access 3306
- "3306:3306"
volumes:
# NOTE: your data will be stored in ./mysql
- ./mysql:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=mypassword
- IPV4_NETWORK=172.18.0
links:
- mailcatcher:mailcatcher
networks:
nibiru-network:
aliases:
- mysql
# mailcatcher
mailcatcher:
image: schickling/mailcatcher:latest
ports:
# Allow client to access 1025, 1080
- "1025:1025"
- "1080:1080"
environment:
- IPV4_NETWORK=172.18.0
networks:
nibiru-network:
aliases:
- mailcatcher
networks:
nibiru-network:
driver: bridge
driver_opts:
com.docker.network.bridge.name: br-nibiru
ipam:
driver: default
config:
- subnet: 172.18.0.0/24