forked from Jungle-Leung/docker-thinkphp5
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
63 lines (57 loc) · 1.48 KB
/
docker-compose.yml
File metadata and controls
63 lines (57 loc) · 1.48 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
version: "3"
services:
nginx:
build: ./services/nginx
container_name: dt5_nginx
depends_on:
- php
ports:
- ${NGINX_PORT}:80
volumes:
- ${APPLICATION}:/var/www/html:rw
- ${LOG_PATH}:/var/log/nginx:rw
- ${NGINX_VHOST_PATH}:/etc/nginx/conf.d/:ro
- ${NGINX_CONFIG_FILENAME}:/etc/nginx/nginx.conf:ro
php:
build: ./services/php
container_name: dt5_php
expose:
- "9000"
links:
- mysql
volumes:
- ${APPLICATION}:/var/www/html:rw
- ${LOG_PATH}:/var/log:rw
- ${PHP_INI_PATH}:/usr/local/etc/php/php.ini:ro
- ${PHP_FPM_PATH}:/usr/local/etc/php-fpm.d/www.conf:rw
mysql:
build: ./services/mysql
container_name: dt5_mysql
ports:
- ${MYSQL_PORT}:3306
volumes:
- ${MYSQL_DATA_PATH}:/var/lib/mysql/:rw
- ${MYSQL_CONFIG_FILENAME}:/etc/mysql/conf.d/mysql.cnf:ro
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_USER: ${MYSQL_USER}
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
MYSQL_DATABASE: ${MYSQL_DATABASE}
redis:
build: ./services/redis
container_name: dt5_redis
ports:
- ${REDIS_PORT}:6379
volumes:
- ${REDIS_DATA_PATH}:/data
- ${REDIS_CONFIG_FILENAME}:/usr/local/etc/redis/redis.conf
composer:
build: ./services/composer
container_name: dt5_composer
depends_on:
- mysql
- redis
- php
- nginx
volumes:
- ${APPLICATION}:/home/www-data:rw