-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
90 lines (84 loc) · 1.96 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
88
89
90
version: '3'
services:
rails:
container_name: ors-rails
build:
dockerfile: Dockerfile
command: /bin/bash -l -c "rm -f /railsapp/tmp/pids/server.pid && bundle install && bundle exec rails s -p 3000 -b '0.0.0.0'"
volumes:
- '.:/railsapp'
- ors_bundler_gems:/usr/local/bundle
- ~/.ssh:/root/.ssh:ro
ports:
- '${ORS_CONTAINER_RAILS_PORT:-3000}:3000'
networks:
- ors
stdin_open: true
tty: true
depends_on:
- redis
- db
- mailcatcher
environment:
REDIS_URL: redis://ors-redis:6379/0
ORS_SMTP_ADDRESS: ors-mailcatcher
db:
container_name: ors-db
image: postgres:9.4
healthcheck:
test: ["CMD", "pg_isready", "-U", "postgres"]
timeout: 45s
interval: 10s
retries: 10
volumes:
- 'ors_pgdata:/var/lib/postgresql/data'
ports:
- "5432:5432"
networks:
- ors
environment:
POSTGRES_HOST_AUTH_METHOD: "trust"
POSTGRES_DB: "ort_development"
redis:
container_name: ors-redis
image: redis
ports:
- "6379:6379"
networks:
- ors
command: redis-server --save 20 1 --loglevel warning
volumes:
- ors_redis_data:/data
sidekiq:
container_name: ors-sidekiq
build:
dockerfile: Dockerfile
networks:
- ors
depends_on:
- db
- redis
- mailcatcher
command: /bin/bash -l -c "mkdir -p /tmp/pids && bundle install && bundle exec sidekiq -C config/sidekiq.yml"
volumes:
- '.:/railsapp'
- ors_bundler_gems:/usr/local/bundle
- ~/.ssh:/root/.ssh:ro
environment:
REDIS_URL: redis://ors-redis:6379/0
ORS_SMTP_ADDRESS: ors-mailcatcher
mailcatcher:
container_name: ors-mailcatcher
image: sj26/mailcatcher
ports:
- '${ORS_CONTAINER_MAILCATCHER_PORT:-1080}:1080'
networks:
- ors
networks:
ors:
driver: bridge
volumes:
ors_pgdata:
ors_node_modules:
ors_redis_data:
ors_bundler_gems: