forked from pvtl/docker-dev
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
executable file
·250 lines (236 loc) · 6.19 KB
/
Copy pathdocker-compose.yml
File metadata and controls
executable file
·250 lines (236 loc) · 6.19 KB
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
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
version: '3'
networks:
# Default Network ------------------------------------------
lde-network:
ipam:
config:
- subnet: 192.168.103.0/24
services:
# Apache ---------------------------------------------------
apache:
container_name: apache
hostname: apache
restart: ${DOCKER_RESTART}
build:
context: ./apache
dockerfile: ./Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_APACHE}
ports:
- "80:80"
volumes:
- ./apache/sites:/usr/local/apache2/conf/sites:ro
- ${DOCUMENTROOT}:/var/www/html:delegated
links:
- php56-fpm
- php70-fpm
- php71-fpm
- php72-fpm
- php73-fpm
- php74-fpm
- php80-fpm
env_file:
- .env
networks:
lde-network:
ipv4_address: 192.168.103.100
# Blackfire ---------------------------------------------------
# blackfire:
# container_name: blackfire
# hostname: blackfire
# restart: ${DOCKER_RESTART}
# image: blackfire/blackfire
# env_file:
# - .env
# networks:
# lde-network:
# HTTPS ---------------------------------------------------
# https:
# container_name: https
# hostname: https
# build: ./https
# ports:
# - "443:443"
# restart: ${DOCKER_RESTART}
# environment:
# - HOST_IP=192.168.103.100
# - PORT=80
# networks:
# lde-network:
# Mailhog ---------------------------------------------------
mailhog:
container_name: mailhog
hostname: mailhog
restart: ${DOCKER_RESTART}
image: mailhog/mailhog
ports:
- "1025:1025"
- "8025:8025"
networks:
lde-network:
# Memcached ---------------------------------------------------
memcached:
container_name: memcached
hostname: memcached
restart: ${DOCKER_RESTART}
image: "memcached:1-alpine"
networks:
lde-network:
# MySQL ---------------------------------------------------
mysql:
container_name: mysql
hostname: mysql
restart: ${DOCKER_RESTART}
build:
context: ./mysql
dockerfile: ./Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_MYSQL}
env_file:
- .env
ports:
- "3306:3306"
volumes:
- ./mysql/data:/var/lib/mysql
command: mysqld --sql_mode=""
networks:
lde-network:
# PHP 5.6 ---------------------------------------------------
php56-fpm:
container_name: php56
hostname: php56
build:
context: ./php
dockerfile: ./56/Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_PHP56}
- CUSTOM_USER_NAME=${CUSTOM_USER_NAME}
- CUSTOM_UID=${CUSTOM_UID}
- CUSTOM_GID=${CUSTOM_GID}
restart: ${DOCKER_RESTART}
volumes:
- ${DOCUMENTROOT}:/var/www/html:delegated
networks:
lde-network:
user: ${CUSTOM_UID}:${CUSTOM_GID}
# PHP 7.0 ---------------------------------------------------
php70-fpm:
container_name: php70
hostname: php70
build:
context: ./php
dockerfile: ./70/Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_PHP70}
- CUSTOM_USER_NAME=${CUSTOM_USER_NAME}
- CUSTOM_UID=${CUSTOM_UID}
- CUSTOM_GID=${CUSTOM_GID}
restart: ${DOCKER_RESTART}
volumes:
- ${DOCUMENTROOT}:/var/www/html:delegated
networks:
lde-network:
user: ${CUSTOM_UID}:${CUSTOM_GID}
# PHP 7.1 ---------------------------------------------------
php71-fpm:
container_name: php71
hostname: php71
build:
context: ./php
dockerfile: ./71/Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_PHP71}
- CUSTOM_USER_NAME=${CUSTOM_USER_NAME}
- CUSTOM_UID=${CUSTOM_UID}
- CUSTOM_GID=${CUSTOM_GID}
restart: ${DOCKER_RESTART}
volumes:
- ${DOCUMENTROOT}:/var/www/html:delegated
networks:
lde-network:
user: ${CUSTOM_UID}:${CUSTOM_GID}
# PHP 7.2 ---------------------------------------------------
php72-fpm:
container_name: php72
hostname: php72
build:
context: ./php
dockerfile: ./72/Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_PHP72}
- CUSTOM_USER_NAME=${CUSTOM_USER_NAME}
- CUSTOM_UID=${CUSTOM_UID}
- CUSTOM_GID=${CUSTOM_GID}
restart: ${DOCKER_RESTART}
volumes:
- ${DOCUMENTROOT}:/var/www/html:delegated
networks:
lde-network:
user: ${CUSTOM_UID}:${CUSTOM_GID}
# PHP 7.3 ---------------------------------------------------
php73-fpm:
container_name: php73
hostname: php73
build:
context: ./php
dockerfile: ./73/Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_PHP73}
- CUSTOM_USER_NAME=${CUSTOM_USER_NAME}
- CUSTOM_UID=${CUSTOM_UID}
- CUSTOM_GID=${CUSTOM_GID}
restart: ${DOCKER_RESTART}
volumes:
- ${DOCUMENTROOT}:/var/www/html:delegated
networks:
lde-network:
user: ${CUSTOM_UID}:${CUSTOM_GID}
# PHP 7.4 ---------------------------------------------------
php74-fpm:
container_name: php74
hostname: php74
build:
context: ./php
dockerfile: ./74/Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_PHP74}
- CUSTOM_USER_NAME=${CUSTOM_USER_NAME}
- CUSTOM_UID=${CUSTOM_UID}
- CUSTOM_GID=${CUSTOM_GID}
restart: ${DOCKER_RESTART}
ports:
- "3000:3000" # Browser Sync
- "3001:3001" # Browser Sync UI
volumes:
- ${DOCUMENTROOT}:/var/www/html:delegated
networks:
lde-network:
user: ${CUSTOM_UID}:${CUSTOM_GID}
# PHP 8.0 ---------------------------------------------------
php80-fpm:
container_name: php80
hostname: php80
build:
context: ./php
dockerfile: ./80/Dockerfile
args:
- EXTRA_CMDS=${EXTRA_CMDS_PHP80}
- CUSTOM_USER_NAME=${CUSTOM_USER_NAME}
- CUSTOM_UID=${CUSTOM_UID}
- CUSTOM_GID=${CUSTOM_GID}
restart: ${DOCKER_RESTART}
volumes:
- ${DOCUMENTROOT}:/var/www/html:delegated
networks:
lde-network:
user: ${CUSTOM_UID}:${CUSTOM_GID}
# Redis ---------------------------------------------------
redis:
container_name: redis
hostname: redis
restart: ${DOCKER_RESTART}
image: "redis:6-alpine"
ports:
- "6379:6379"
networks:
lde-network: