-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose.yaml
91 lines (91 loc) · 2.33 KB
/
docker-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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
version: '2'
services:
lb:
image: 'dockercloud/haproxy:1.5.3'
links:
- node:node
- static:static
ports:
- '80:80'
volumes:
- /var/run/docker.sock:/var/run/docker.sock
node:
build:
context: .
dockerfile: Dockerfile-node
links:
- mongo1
- mongo2
- mongo3
- elasticsearch
- redis
volumes:
- ./server:/src/server
ports:
- "80"
environment:
- NODE_ENV=sandbox
- VIRTUAL_HOST=http://api.ldir.ro
- STATIC_SITE=http://ldir.ro
- FACEBOOK_API_URL=https://graph.facebook.com/v2.3/
entrypoint:
- node
- /src/server/app.js
kue:
build:
context: .
dockerfile: Dockerfile-node
links:
- mongo1
- mongo2
- mongo3
- redis
volumes:
- ./server:/src/server
- ~/ldir-volumes/storage/temp:/src/uploads
environment:
- NODE_ENV=sandbox
command: node server/queue.js
static:
build:
context: ./
dockerfile: Dockerfile-static
volumes:
- ./client:/usr/share/nginx/html
- ./configs/sites:/etc/nginx/conf.d
ports:
- "80"
environment:
- VIRTUAL_HOST=ldir.ro:80
elasticsearch:
image: elasticsearch:1.5
ports:
- "9200"
- "9300"
volumes:
- ~/ldir-volumes/elasticsearch:/usr/share/elasticsearch/data/elasticsearch
mongo1:
image: mongo:3.3
volumes:
- ~/ldir-volumes/mongo/db-1:/data/db
command: mongod --replSet "rs"
mongo2:
image: mongo:3.3
volumes:
- ~/ldir-volumes/mongo/db-2:/data/db
command: mongod --replSet "rs"
mongo3:
image: mongo:3.3
volumes:
- ~/ldir-volumes/mongo/db-3:/data/db
command: mongod --replSet "rs"
redis:
image: redis:3.2
volumes:
- ~/ldir-volumes/redis:/data
mongosetup:
image: levino/mongo-rs-setup
links:
- mongo1:mongo1
- mongo2:mongo2
- mongo3:mongo3