forked from covoiturage-libre/covoiturage-libre
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
61 lines (55 loc) · 1.5 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
version: '2.1'
services:
db:
restart: always
image: mdillon/postgis
environment:
- POSTGRES_PASSWORD=password
### Uncomment to enable DB persistance
# volumes:
# - ./postgres:/var/lib/postgresql/data
redis:
restart: always
image: redis
### Uncomment to enable REDIS persistance
# volumes:
# - ./redis:/data
elasticsearch:
restart: always
image: docker.elastic.co/elasticsearch/elasticsearch:5.2.2
### Uncomment to enable ELASTICSEARCH persistance
# volumes:
# - ./elasticsearch:/var/lib/elasticsearch/data
web:
restart: always
build:
context: .
command: bash -c "bundle exec rake db:migrate && bundle exec rake searchkick:reindex CLASS=City && bundle exec puma -t 5:5 -p 3000 -e ${RACK_ENV:-development}"
ports:
- "3000:3000"
depends_on:
- db
- elasticsearch
- redis
volumes:
- .:/covoiturage-libre
environment:
- DATABASE_URL=postgresql://postgres:password@db:5432/postgres
- ELASTICSEARCH_URL=http://elastic:changeme@elasticsearch:9200
- REDIS_URL=redis://redis:6379
delayedjob:
build:
context: .
command: bash -c "bin/delayed_job run"
ports:
- "3001:3000"
depends_on:
- db
- elasticsearch
- redis
volumes:
- .:/covoiturage-libre
environment:
- DATABASE_URL=postgresql://postgres:password@db:5432/postgres
- ELASTICSEARCH_URL=http://elastic:changeme@elasticsearch:9200
- REDIS_URL=redis://redis:6379