-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
108 lines (97 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
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
version: "3.7"
# See https://github.com/UoGSoE/docker-stuff for the origins of this file
x-env:
environment: &default-env
MAIL_DRIVER: smtp
MAIL_HOST: mailhog
MAIL_PORT: 1025
REDIS_HOST: redis
QUEUE_CONNECTION: redis
SESSION_DRIVER: redis
DB_CONNECTION: mysql
DB_HOST: mysql
DB_PORT: 3306
DB_DATABASE: homestead
DB_USERNAME: homestead
DB_PASSWORD: secret
services:
app:
image: ${IMAGE_NAME}
environment:
CONTAINER_ROLE: app
<<: *default-env
ports:
- "${APP_PORT:-3000}:80"
build:
context: .
target: dev
volumes:
- .:/var/www/html
secrets:
- source: dotenv
target: .env
depends_on:
- redis
- mysql
- mailhog
scheduler:
image: ${IMAGE_NAME}
environment:
CONTAINER_ROLE: scheduler
<<: *default-env
depends_on:
- app
volumes:
- .:/var/www/html
secrets:
- source: dotenv
target: .env
queue:
image: ${IMAGE_NAME}
environment:
CONTAINER_ROLE: queue
<<: *default-env
depends_on:
- app
volumes:
- .:/var/www/html
secrets:
- source: dotenv
target: .env
migrations:
image: ${IMAGE_NAME}
environment:
CONTAINER_ROLE: migrations
<<: *default-env
depends_on:
- app
volumes:
- .:/var/www/html
secrets:
- source: dotenv
target: .env
redis:
image: redis:5.0.4
volumes:
- redis:/data
mysql:
image: mysql:5.7
volumes:
- mysql:/var/lib/mysql
environment:
MYSQL_DATABASE: homestead
MYSQL_ROOT_PASSWORD: root
MYSQL_USER: homestead
MYSQL_PASSWORD: secret
mailhog:
image: mailhog/mailhog
ports:
- "3025:8025"
volumes:
redis:
driver: "local"
mysql:
driver: "local"
secrets:
dotenv:
file: ./.env