-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
64 lines (59 loc) · 1.35 KB
/
docker-compose.yml
File metadata and controls
64 lines (59 loc) · 1.35 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
64
version: '2'
services:
mysql:
build: ./docker/mysql
ports:
- "3312:3306"
volumes:
- "./volumes/mysql:/var/lib/mysql"
environment:
MYSQL_DATABASE: test
MYSQL_USER: test
MYSQL_PASSWORD: test
MYSQL_ALLOW_EMPTY_PASSWORD: 'yes'
command:
- '--default-authentication-plugin=mysql_native_password'
- '--character-set-server=utf8mb4'
php-fpm:
build: ./docker/php
links:
- mysql
volumes:
- "./app:/app"
environment:
DB_HOST: mysql
nginx:
build: ./docker/nginx
volumes:
- "./app:/app"
- "./docker/nginx/vhost.conf:/etc/nginx/conf.d/default.conf"
- "./docker/nginx/nginx.conf:/etc/nginx/nginx.conf"
links:
- php-fpm
ports:
- "8010:80"
redis:
image: redis:latest
volumes:
- "/.redis:/data"
ports:
- '6379:6379'
cron:
build: ./docker/php
restart: always
command: bash -c "echo '* * * * * root cd /app && php artisan schedule:run >> /dev/null 2>&1' >> /etc/crontab && chmod +x /app/cron.sh && /app/cron.sh"
links:
- mysql
volumes:
- "./app:/app"
environment:
DB_HOST: mysql
laravel-worker:
build: ./docker/php
links:
- mysql
volumes:
- "./app:/app"
environment:
DB_HOST: mysql
command: "php artisan queue:work --daemon"