-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathdocker-compose.yml
58 lines (54 loc) · 1.26 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
version: "3.3"
services:
php:
build: ./
restart: always
volumes:
- "./:/var/www/html"
depends_on:
- mysql
environment:
APP_ENV: local
APP_KEY: base64:q88n99GBruM6uinDPZo1KEKVPt1/CCMqU9cP91cZTsc=
APP_DEBUG: 'true'
APP_URL: http://localhost
APP_TIMEZONE: 'Asia/Taipei'
DB_CONNECTION: mysql
DB_HOST: mysql
DB_PORT: 3306
DB_DATABASE: mopcon
DB_USERNAME: mopcon
DB_PASSWORD: password
DB_ROOT_PW: password
node:
image: node:12
working_dir: "/usr/src/app"
volumes:
- "./:/usr/src/app"
entrypoint: bash -c "sleep infinity"
command: bash -c "yarn install && yarn run dev" # use bash or ash
mysql:
image: mysql:5.7
restart: always
environment:
MYSQL_DATABASE: mopcon
MYSQL_USER: mopcon
MYSQL_PASSWORD: password
MYSQL_ROOT_PASSWORD: password
ports:
- 3306:3306
volumes:
- ./mysql:/var/lib/mysql
- ./log/mysql:/var/log/mysql
nginx:
image: nginx:latest
restart: always
ports:
- 81:80
volumes:
- "./:/var/www/html"
- "./log/nginx:/var/log/nginx"
- "./files/nginx/conf.d/default.conf:/etc/nginx/conf.d/default.conf"
depends_on:
- node
- php