-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose.yml
executable file
·78 lines (73 loc) · 1.86 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
version: "3.9"
services:
nginx:
image: ${NGINX}
container_name: nginx
restart: unless-stopped
ports:
- "80:80"
- "443:443"
environment:
- TZ=${TIMEZONE}
volumes:
- ${APP}:${CONTAINER}:ro
- ${CONFIG}/nginx:/etc/nginx/conf.d:ro
networks:
- web
php:
image: ${PHP}
restart: unless-stopped
container_name: php
user: ${UID}:${GID}
volumes:
- ${APP}:${CONTAINER}:rw
- ${CONFIG}/php/docker-upload.ini:/usr/local/etc/php/conf.d/docker-upload.ini:ro
- ${CONFIG}/php/www.conf:/usr/local/etc/php-fpm.d/www.conf:ro
ports:
- "9000:9000"
depends_on:
- nginx
networks:
- web
mysql:
image: ${MYSQL}
container_name: mysql
restart: unless-stopped
expose:
- "3306"
ports:
- "3306:3306"
environment:
- MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
- MYSQL_DATABASE=${MYSQL_DATABASE}
- MYSQL_USER=${MYSQL_USER}
- MYSQL_PASSWORD=${MYSQL_PASSWORD}
- TZ=${TIMEZONE}
volumes:
- ${DATABASE}/mysql:/var/lib/mysql:rw
command:
--lower_case_table_names=${LOWER_CASE_TABLE_NAMES}
--character-set-server=${CHARACTER_SET_SERVER}
--collation-server=${COLLATION_SERVER}
--explicit_defaults_for_timestamp=${EXPLICIT_DEFAULTS_FOR_TIMESTAMP}
--default-storage-engine=${DEFAULT_STORAGE_ENGINE}
--sql_mode=${SQL_MODE}
networks:
- web
redis:
image: ${REDIS}
container_name: redis
restart: unless-stopped
ports:
- "6379:6379"
command: redis-server /usr/local/etc/redis/redis.conf
environment:
- TZ=${TIMEZONE}
volumes:
- ${CONFIG}/redis/redis.conf:/usr/local/etc/redis/redis.conf:ro
- ${DATABASE}/redis:/data:rw
- ${STORAGE}/logs/redis/redis.log:/var/log/redis.log:rw
networks:
- web
networks:
web: