-
Notifications
You must be signed in to change notification settings - Fork 43
/
docker-compose.yml
115 lines (114 loc) · 2.38 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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
version: '3'
networks:
development:
test:
volumes:
db_data:
gem_cache:
shared_data:
services:
solutions_redis:
image: 'redis:4.0-alpine'
command: redis-server
container_name: solutions_redis
networks:
- development
- test
volumes:
- 'shared_data:/var/shared/redis'
ports:
- 6380:6379
solutions_db:
image: postgres:12.5-alpine
container_name: solutions_db
volumes:
- db_data:/var/lib/postgresql/data
- shared_data:/var/shared
networks:
- development
- test
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
ports:
- 6000:5432
solutions_sidekiq:
depends_on:
- solutions_db
- solutions_redis
image: violet_rails_solutions_app
container_name: solutions_sidekiq
command: sidekiq -c 1
volumes:
- .:/var/app
- shared_data:/var/shared
- gem_cache:/usr/local/bundle/gems
env_file: .env.development
networks:
- development
- test
ports:
- 5251:5251
mailcatcher:
container_name: mailcatcher
image: yappabe/mailcatcher
networks:
- development
- test
ports:
- 1025:1025
- 1080:1080
solutions_app:
build:
context: .
dockerfile: Dockerfile.dev
container_name: solutions_app
volumes:
- .:/var/app
- shared_data:/var/shared
- gem_cache:/usr/local/bundle/gems
networks:
- development
ports:
- 5250:5250
stdin_open: true
tty: true
env_file: .env.development
entrypoint: entrypoint.sh
command: ['rails', 'server', '-p', '5250', '-b', '0.0.0.0']
environment:
RAILS_ENV: development
depends_on:
- solutions_db
- solutions_redis
solutions_test:
image: violet_rails_solutions_app
container_name: solutions_test
volumes:
- .:/var/app
- shared_data:/var/shared
- gem_cache:/usr/local/bundle/gems
networks:
- test
ports:
- 3001:3000
stdin_open: true
tty: true
env_file: .env.test
entrypoint: test-entrypoint.sh
command: ["rails", "-v"]
environment:
RAILS_ENV: test
depends_on:
- solutions_db
- solutions_app
nginx:
build:
context: .
dockerfile: ./nginx.Dockerfile
depends_on:
- solutions_app
ports:
- 80:80
networks:
- development