-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
55 lines (55 loc) · 1.52 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
version: '3'
services:
# ----------------------------------------------------------
# The Web Serivce
# ----------------------------------------------------------
# This is the entry point for seeing the app in a browser
# You can view your app at localhost:8000
laravel-web:
build:
context: ./
dockerfile: ./docker/Dockerfile.web
volumes:
- ./:/var/www
container_name: laravel-web
ports:
- "8002:80"
links:
- laravel-app
depends_on:
- laravel-app
# ----------------------------------------------------------
# The App Service
# ----------------------------------------------------------
# This is the container that runs the app. The web services
# runs it via a proxy.
laravel-app:
build:
context: ./
dockerfile: ./docker/Dockerfile.app
container_name: laravel-app
volumes:
- ./:/var/www
links:
- laravel-db
depends_on:
- laravel-db
# ----------------------------------------------------------
# The DB Service
# ----------------------------------------------------------
# This is the main db for the app.
laravel-db:
build:
context: ./
dockerfile: ./docker/Dockerfile.db
ports:
- '33062:3306'
container_name: laravel-db
environment:
- MYSQL_ROOT_PASSWORD=rootpassword
- MYSQL_USER=laravel_user
- MYSQL_PASSWORD=laravel_password
- MYSQL_ALLOW_EMPTY_PASSWORD=yes
- MYSQL_DATABASE=laravel
volumes:
- ./data/mysql/data:/var/lib/mysql