-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
87 lines (78 loc) · 1.64 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
# v2 sintax
version: '2'
# Named volumes
volumes:
# MySQL Data
codecasts-mysql-data:
driver: local
# Redis Data
codecasts-redis-data:
driver: local
# Elasticsearch Data
codecasts-elastic-data:
driver: local
services:
# MySQL (5.7)
mysql:
image: ambientum/mysql:5.7
container_name: codecasts-mysql
volumes:
- codecasts-mysql-data:/var/lib/mysql
ports:
- "3306:3306"
environment:
- MYSQL_ROOT_PASSWORD=codecasts
- MYSQL_DATABASE=codecasts
- MYSQL_USER=codecasts
- MYSQL_PASSWORD=codecasts
# Redis
cache:
image: ambientum/redis:3.2
container_name: codecasts-redis
command: --appendonly yes
volumes:
- codecasts-redis-data:/data
ports:
- "6379:6379"
# PHP (with Caddy)
api:
image: ambientum/php:7.0-caddy
container_name: codecasts-php
volumes:
- .:/var/www/app
ports:
- "80:8080"
links:
- mysql
- cache
- elastic
# Laravel Queues
queue:
image: ambientum/php:7.0
container_name: codecasts-queue
command: php artisan queue:listen
volumes:
- .:/var/www/app
links:
- mysql
- cache
- elastic
# Elastic Search
elastic:
image: elasticsearch:2.3
container_name: codecasts-elastic
volumes:
- codecasts-elastic-data:/usr/share/elasticsearch/data
ports:
- "9200:9200"
- "9300:9300"
# SPA mockup, just for testing the auth flow
mockup-spa:
image: ambientum/php:7.0-caddy
container_name: codecasts-mockup-spa
ports:
- "9090:8080"
volumes:
- ./mockup-spa:/var/www/app/public
links:
- api