-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
115 lines (106 loc) · 3.56 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
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
version: '3'
networks:
frontend:
driver: ${NETWORKS_DRIVER}
backend:
driver: ${NETWORKS_DRIVER}
volumes:
redis:
driver: ${VOLUMES_DRIVER}
services:
### Workspace Utilities ##################################
workspace:
image: aidong-backend.tencentcloudcr.com/aidong/php-workspace:1.2.0
volumes:
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
- ./php-worker/supervisord.d:/etc/supervisord.d
- ./php-worker/supervisord.conf:/etc/supervisord.conf
- ./workspace/yaconf:/usr/local/etc/yaconf
- ./workspace/xdebug.ini:/etc/php/7.2/cli/conf.d/xdebug.ini
extra_hosts:
- "homestead.linde:172.20.0.1"
- "homestead.linde.fastapi:172.20.0.1"
- "homestead.hbsd:172.20.0.1"
- "homestead.watch:172.20.0.1"
- "homestead.watch.fastapi:172.20.0.1"
- "homestead.linde.cms:172.20.0.1"
- "homestead.td:172.20.0.1"
ports:
- "25080:25080"
- "25081:25081"
tty: true
environment:
- PHP_IDE_CONFIG=${PHP_IDE_CONFIG}
networks:
- frontend
- backend
### PHP-FPM ##############################################
php-fpm:
image: aidong-backend.tencentcloudcr.com/aidong/php-fpm:1.2.0
volumes:
- ./php-fpm/php${PHP_VERSION}.ini:/usr/local/etc/php/php.ini
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
- ./php-fpm/xdebug.ini:/usr/local/etc/php/conf.d/xdebug.ini
ports:
- "${PHP_FPM_XDEBUG_PORT}:9003"
expose:
- "9000"
extra_hosts:
- "homestead.linde:172.20.0.1"
- "homestead.linde.fastapi:172.20.0.1"
- "homestead.hbsd:172.20.0.1"
- "homestead.watch:172.20.0.1"
- "homestead.watch.fastapi:172.20.0.1"
- "homestead.linde.cms:172.20.0.1"
- "homestead.td:172.20.0.1"
environment:
- PHP_IDE_CONFIG=${PHP_IDE_CONFIG}
- FAKETIME=${PHP_FPM_FAKETIME}
depends_on:
- workspace
networks:
- backend
### PHP Worker ############################################
php-worker:
image: aidong-backend.tencentcloudcr.com/aidong/php-worker:1.1.0
volumes:
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
- ./php-worker/supervisord.d:/etc/supervisord.d
- ./php-worker/supervisord.conf:/etc/supervisord.conf
depends_on:
- workspace
extra_hosts:
- "homestead.linde:172.20.0.1"
- "homestead.linde.fastapi:172.20.0.1"
- "homestead.hbsd:172.20.0.1"
- "homestead.watch:172.20.0.1"
- "homestead.watch.fastapi:172.20.0.1"
- "homestead.linde.cms:172.20.0.1"
- "homestead.td:172.20.0.1"
networks:
- backend
### NGINX Server #########################################
nginx:
image: aidong-backend.tencentcloudcr.com/aidong/php-nginx:1.1.0
volumes:
- ${APP_CODE_PATH_HOST}:${APP_CODE_PATH_CONTAINER}${APP_CODE_CONTAINER_FLAG}
- ${NGINX_HOST_LOG_PATH}:/var/log/nginx
- ${NGINX_SITES_PATH}:/etc/nginx/sites-available
- ${NGINX_SSL_PATH}:/etc/nginx/ssl
ports:
- "${NGINX_HOST_HTTP_PORT}:80"
- "${NGINX_HOST_HTTPS_PORT}:443"
depends_on:
- php-fpm
networks:
- frontend
- backend
### Redis ################################################
redis:
image: redis:latest
volumes:
- ${DATA_PATH_HOST}/redis:/data
ports:
- "${REDIS_PORT}:6379"
networks:
- backend