-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
executable file
·122 lines (122 loc) · 3.31 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
115
116
117
118
119
120
121
122
version: "3"
services:
php5:
container_name: ws-php5
hostname: php5
restart: "unless-stopped"
build:
dockerfile: Dockerfile
context: php5
args:
LANGUAGE: ${LANGUAGE}
TIMEZONE: ${TIMEZONE}
depends_on:
- db
- redis
environment:
- PHP_IDE_CONFIG=serverName=XdebugServer
volumes:
- "./default/.bashrc:/root/.bashrc"
- "./php5/conf.d/99-custom.ini:/usr/local/etc/php/conf.d/99-custom.ini"
- "./logs:/var/log"
- "../:/var/www/html"
- "~/.ssh:/~/.ssh"
expose:
- "9000"
ports:
- '9000:9000'
stdin_open: true
tty: true
networks:
ws-network:
ipv4_address: 172.8.0.10
php7:
container_name: ws-php7
hostname: php7
restart: "unless-stopped"
build:
dockerfile: Dockerfile
context: php7
args:
LANGUAGE: ${LANGUAGE}
TIMEZONE: ${TIMEZONE}
depends_on:
- db
- redis
environment:
- SYMFONY_ENV=dev
- PHP_IDE_CONFIG=serverName=XdebugServer
volumes:
- "./default/.bashrc:/root/.bashrc"
- "./php7/conf.d/99-custom.ini:/usr/local/etc/php/conf.d/99-custom.ini"
- "./logs:/var/log"
- "../:/var/www/html"
- "~/.ssh:/~/.ssh"
expose:
- '9000'
ports:
- '9007:9000'
stdin_open: true
tty: true
networks:
ws-network:
ipv4_address: 172.8.0.11
db:
image: "mysql:5.6"
container_name: ws-mysql
hostname: mysql
restart: "unless-stopped"
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_USER: ${MYSQL_USER}
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
MYSQL_DATABASE: ${MYSQL_DATABASE}
volumes:
- "./default/.bashrc:/root/.bashrc"
- "./mysql/conf.d/custom.cnf:/etc/mysql/conf.d/custom.cnf"
- "./mysql/data:/var/lib/mysql:rw"
ports:
- "3303:3306"
networks:
ws-network:
ipv4_address: 172.8.0.15
redis:
image: "redis:7.4.2-alpine"
container_name: cacheserver
restart: "unless-stopped"
ports:
- "6379:6379"
networks:
ws-network:
ipv4_address: 172.8.0.16
nginx:
container_name: ws-nginx
hostname: nginx
restart: "unless-stopped"
build:
dockerfile: Dockerfile
context: nginx
volumes:
- "./nginx/nginx.conf:/etc/nginx/nginx.conf"
- "./logs:/var/log/nginx"
- "../:/var/www/html"
ports:
- '80:80'
- 443:443
depends_on:
- php5
- php7
links:
- php5
- php7
networks:
ws-network:
ipv4_address: 172.8.0.17
networks:
ws-network:
name: "ws-network"
driver: bridge
ipam:
driver: default
config:
- subnet: 172.8.0.0/24