-
Notifications
You must be signed in to change notification settings - Fork 379
/
compose.yaml
67 lines (63 loc) · 1.61 KB
/
compose.yaml
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
volumes:
db-store:
services:
app:
build:
context: .
dockerfile: ./infra/docker/php/Dockerfile
args:
UID: ${UID:-1000}
GID: ${GID:-1000}
target: ${APP_BUILD_TARGET:-development}
volumes:
- type: bind
source: ./src
target: /workspace
environment:
# Please remove this environment variable, after created the Laravel project. Please write in .env
- DB_CONNECTION=${DB_CONNECTION:-mysql}
- DB_HOST=${DB_HOST:-db}
- DB_PORT=${DB_PORT:-3306}
- DB_DATABASE=${DB_DATABASE:-laravel}
- DB_USERNAME=${DB_USERNAME:-phper}
- DB_PASSWORD=${DB_PASSWORD:-secret}
web:
build:
context: .
dockerfile: ./infra/docker/nginx/Dockerfile
ports:
- target: 80
published: ${WEB_PUBLISHED_PORT:-80}
protocol: tcp
mode: host
volumes:
- type: bind
source: ./src
target: /workspace
db:
build:
context: .
dockerfile: ./infra/docker/mysql/Dockerfile
ports:
- target: 3306
published: ${DB_PUBLISHED_PORT:-3306}
protocol: tcp
mode: host
volumes:
- type: volume
source: db-store
target: /var/lib/mysql
volume:
nocopy: true
environment:
- MYSQL_DATABASE=${DB_DATABASE:-laravel}
- MYSQL_USER=${DB_USERNAME:-phper}
- MYSQL_PASSWORD=${DB_PASSWORD:-secret}
- MYSQL_ROOT_PASSWORD=${DB_PASSWORD:-secret}
mailpit:
image: axllent/mailpit
ports:
- target: 8025
published: ${MAILPIT_PUBLISHED_PORT:-8025}
protocol: tcp
mode: host