質問編集履歴
6
コード追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -238,7 +238,7 @@
|
|
238
238
|
|
239
239
|
```
|
240
240
|
|
241
|
-
**<追記> docker-compose.yml**
|
241
|
+
**<追記> docker-compose.yml 文字数制限のためMySQL部分のみの表示です**
|
242
242
|
|
243
243
|
```
|
244
244
|
|
5
コード追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -6,11 +6,7 @@
|
|
6
6
|
|
7
7
|
|
8
8
|
|
9
|
-
|
9
|
+
[https://qiita.com/dnrsm/items/4bd078c17bb0d6888647](http://https://qiita.com/dnrsm/items/4bd078c17bb0d6888647)
|
10
|
-
|
11
|
-
https://qiita.com/dnrsm/items/4bd078c17bb0d6888647
|
12
|
-
|
13
|
-
```
|
14
10
|
|
15
11
|
|
16
12
|
|
4
コード追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -390,7 +390,7 @@
|
|
390
390
|
|
391
391
|
```
|
392
392
|
|
393
|
-
|
393
|
+
[https://qiita.com/J_Shell/items/695a30fd38444d065ae5](http://https://qiita.com/J_Shell/items/695a30fd38444d065ae5)
|
394
394
|
|
395
395
|
|
396
396
|
|
3
コード追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -388,8 +388,14 @@
|
|
388
388
|
|
389
389
|
- backend
|
390
390
|
|
391
|
-
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
```
|
391
|
+
```
|
392
|
+
|
393
|
+
> https://qiita.com/J_Shell/items/695a30fd38444d065ae5
|
394
|
+
|
395
|
+
|
396
|
+
|
397
|
+
こちらの記事でも試しましたが、
|
398
|
+
|
399
|
+
applicationsのvolumesの記載がなかったため変更ができず
|
400
|
+
|
401
|
+
何も触っていません。
|
2
コード追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -241,3 +241,155 @@
|
|
241
241
|
5acb64003410 docker:dind "dockerd-entrypoint.…" 27 hours ago Up 56 minutes 2375-2376/tcp
|
242
242
|
|
243
243
|
```
|
244
|
+
|
245
|
+
**<追記> docker-compose.yml**
|
246
|
+
|
247
|
+
```
|
248
|
+
|
249
|
+
version: '3'
|
250
|
+
|
251
|
+
|
252
|
+
|
253
|
+
networks:
|
254
|
+
|
255
|
+
frontend:
|
256
|
+
|
257
|
+
driver: ${NETWORKS_DRIVER}
|
258
|
+
|
259
|
+
backend:
|
260
|
+
|
261
|
+
driver: ${NETWORKS_DRIVER}
|
262
|
+
|
263
|
+
|
264
|
+
|
265
|
+
volumes:
|
266
|
+
|
267
|
+
mysql:
|
268
|
+
|
269
|
+
driver: ${VOLUMES_DRIVER}
|
270
|
+
|
271
|
+
percona:
|
272
|
+
|
273
|
+
driver: ${VOLUMES_DRIVER}
|
274
|
+
|
275
|
+
mssql:
|
276
|
+
|
277
|
+
driver: ${VOLUMES_DRIVER}
|
278
|
+
|
279
|
+
postgres:
|
280
|
+
|
281
|
+
driver: ${VOLUMES_DRIVER}
|
282
|
+
|
283
|
+
memcached:
|
284
|
+
|
285
|
+
driver: ${VOLUMES_DRIVER}
|
286
|
+
|
287
|
+
redis:
|
288
|
+
|
289
|
+
driver: ${VOLUMES_DRIVER}
|
290
|
+
|
291
|
+
neo4j:
|
292
|
+
|
293
|
+
driver: ${VOLUMES_DRIVER}
|
294
|
+
|
295
|
+
mariadb:
|
296
|
+
|
297
|
+
driver: ${VOLUMES_DRIVER}
|
298
|
+
|
299
|
+
mongo:
|
300
|
+
|
301
|
+
driver: ${VOLUMES_DRIVER}
|
302
|
+
|
303
|
+
minio:
|
304
|
+
|
305
|
+
driver: ${VOLUMES_DRIVER}
|
306
|
+
|
307
|
+
rethinkdb:
|
308
|
+
|
309
|
+
driver: ${VOLUMES_DRIVER}
|
310
|
+
|
311
|
+
phpmyadmin:
|
312
|
+
|
313
|
+
driver: ${VOLUMES_DRIVER}
|
314
|
+
|
315
|
+
adminer:
|
316
|
+
|
317
|
+
driver: ${VOLUMES_DRIVER}
|
318
|
+
|
319
|
+
aerospike:
|
320
|
+
|
321
|
+
driver: ${VOLUMES_DRIVER}
|
322
|
+
|
323
|
+
caddy:
|
324
|
+
|
325
|
+
driver: ${VOLUMES_DRIVER}
|
326
|
+
|
327
|
+
elasticsearch:
|
328
|
+
|
329
|
+
driver: ${VOLUMES_DRIVER}
|
330
|
+
|
331
|
+
mosquitto:
|
332
|
+
|
333
|
+
driver: ${VOLUMES_DRIVER}
|
334
|
+
|
335
|
+
confluence:
|
336
|
+
|
337
|
+
driver: ${VOLUMES_DRIVER}
|
338
|
+
|
339
|
+
sonarqube:
|
340
|
+
|
341
|
+
driver: ${VOLUMES_DRIVER}
|
342
|
+
|
343
|
+
cassandra:
|
344
|
+
|
345
|
+
driver: ${VOLUMES_DRIVER}
|
346
|
+
|
347
|
+
|
348
|
+
|
349
|
+
services:
|
350
|
+
|
351
|
+
|
352
|
+
|
353
|
+
### MySQL ################################################
|
354
|
+
|
355
|
+
mysql:
|
356
|
+
|
357
|
+
build:
|
358
|
+
|
359
|
+
context: ./mysql
|
360
|
+
|
361
|
+
args:
|
362
|
+
|
363
|
+
- MYSQL_VERSION=${MYSQL_VERSION}
|
364
|
+
|
365
|
+
environment:
|
366
|
+
|
367
|
+
- MYSQL_DATABASE=${MYSQL_DATABASE}
|
368
|
+
|
369
|
+
- MYSQL_USER=${MYSQL_USER}
|
370
|
+
|
371
|
+
- MYSQL_PASSWORD=${MYSQL_PASSWORD}
|
372
|
+
|
373
|
+
- MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
|
374
|
+
|
375
|
+
- TZ=${WORKSPACE_TIMEZONE}
|
376
|
+
|
377
|
+
volumes:
|
378
|
+
|
379
|
+
- ${DATA_PATH_HOST}/mysql:/var/lib/mysql
|
380
|
+
|
381
|
+
- ${MYSQL_ENTRYPOINT_INITDB}:/docker-entrypoint-initdb.d
|
382
|
+
|
383
|
+
ports:
|
384
|
+
|
385
|
+
- "${MYSQL_PORT}:3306"
|
386
|
+
|
387
|
+
networks:
|
388
|
+
|
389
|
+
- backend
|
390
|
+
|
391
|
+
|
392
|
+
|
393
|
+
|
394
|
+
|
395
|
+
```
|
1
コード追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -143,3 +143,101 @@
|
|
143
143
|
ご教授いただきたいです。
|
144
144
|
|
145
145
|
よろしくお願い致します。
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
|
150
|
+
|
151
|
+
**--no-cacheをつけて再構築を試してみた結果**
|
152
|
+
|
153
|
+
```
|
154
|
+
|
155
|
+
$ docker-compose build --no-cache mysql
|
156
|
+
|
157
|
+
Building mysql
|
158
|
+
|
159
|
+
Step 1/10 : ARG MYSQL_VERSION=latest
|
160
|
+
|
161
|
+
Step 2/10 : FROM mysql:${MYSQL_VERSION}
|
162
|
+
|
163
|
+
---> cd3ed0dfff7e
|
164
|
+
|
165
|
+
Step 3/10 : LABEL maintainer="Mahmoud Zalt <mahmoud@zalt.me>"
|
166
|
+
|
167
|
+
---> Running in daab6ea0794a
|
168
|
+
|
169
|
+
Removing intermediate container daab6ea0794a
|
170
|
+
|
171
|
+
---> 1943a8fddde6
|
172
|
+
|
173
|
+
Step 4/10 : ARG TZ=UTC
|
174
|
+
|
175
|
+
---> Running in ac35f7f65558
|
176
|
+
|
177
|
+
Removing intermediate container ac35f7f65558
|
178
|
+
|
179
|
+
---> c582f5b86d99
|
180
|
+
|
181
|
+
Step 5/10 : ENV TZ ${TZ}
|
182
|
+
|
183
|
+
---> Running in 0ff53fa7230c
|
184
|
+
|
185
|
+
Removing intermediate container 0ff53fa7230c
|
186
|
+
|
187
|
+
---> d652c99ce8c3
|
188
|
+
|
189
|
+
Step 6/10 : RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone && chown -R mysql:root /var/lib/mysql/
|
190
|
+
|
191
|
+
---> Running in a95b1b2ed26c
|
192
|
+
|
193
|
+
Removing intermediate container a95b1b2ed26c
|
194
|
+
|
195
|
+
---> 2b2cec091ed8
|
196
|
+
|
197
|
+
Step 7/10 : COPY my.cnf /etc/mysql/conf.d/my.cnf
|
198
|
+
|
199
|
+
---> 95ecaebf8ed7
|
200
|
+
|
201
|
+
Step 8/10 : RUN chmod 0444 /etc/mysql/conf.d/my.cnf
|
202
|
+
|
203
|
+
---> Running in 3cfaecc4da23
|
204
|
+
|
205
|
+
Removing intermediate container 3cfaecc4da23
|
206
|
+
|
207
|
+
---> a6b8123a6bd7
|
208
|
+
|
209
|
+
Step 9/10 : CMD ["mysqld"]
|
210
|
+
|
211
|
+
---> Running in b981de656294
|
212
|
+
|
213
|
+
Removing intermediate container b981de656294
|
214
|
+
|
215
|
+
---> b31c4377bc5d
|
216
|
+
|
217
|
+
Step 10/10 : EXPOSE 3306
|
218
|
+
|
219
|
+
---> Running in ca50eda84f9b
|
220
|
+
|
221
|
+
Removing intermediate container ca50eda84f9b
|
222
|
+
|
223
|
+
---> ca92f3ca91cc
|
224
|
+
|
225
|
+
Successfully built ca92f3ca91cc
|
226
|
+
|
227
|
+
Successfully tagged laradock_mysql:latest
|
228
|
+
|
229
|
+
mullan-mac:laradock @@@$ docker container ls
|
230
|
+
|
231
|
+
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
|
232
|
+
|
233
|
+
285e1a3ee342 laradock_phpmyadmin "/docker-entrypoint.…" About an hour ago Up 54 minutes 0.0.0.0:8080->80/tcp laradock_phpmyadmin_1
|
234
|
+
|
235
|
+
e18f799feb80 laradock_nginx "/bin/bash /opt/star…" 27 hours ago Up 56 minutes 0.0.0.0:80->80/tcp, 0.0.0.0:443->443/tcp laradock_nginx_1
|
236
|
+
|
237
|
+
3cfac25ab736 laradock_php-fpm "docker-php-entrypoi…" 27 hours ago Up 56 minutes 9000/tcp laradock_php-fpm_1
|
238
|
+
|
239
|
+
0fce26e9732d laradock_workspace "/sbin/my_init" 27 hours ago Up 56 minutes 0.0.0.0:2222->22/tcp laradock_workspace_1
|
240
|
+
|
241
|
+
5acb64003410 docker:dind "dockerd-entrypoint.…" 27 hours ago Up 56 minutes 2375-2376/tcp
|
242
|
+
|
243
|
+
```
|