-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
52 lines (46 loc) · 1.09 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
version: '3.9'
services:
web:
build: .
volumes: &web-volumes
- &app-volume .:/arms_webapp:cached
- ~/.ssh:/root/.ssh
- ~/.bash_history:/root/.bash_history
- &bundle-cache-volume bundle_cache:/bundle_cache
ports:
- 80:3000
depends_on:
- db
- redis
- sidekiq
environment: &web-environment
REDIS_URL: redis://redis
BUNDLE_PATH: /bundle_cache
GEM_HOME: /bundle_cache
GEM_PATH: /bundle_cache
RAILS_PORT: 3000
RUBYOPT: -W:no-deprecated -W:no-experimental
DATABASE_HOST: db
DATABASE_USERNAME: postgres
DATABASE_PASSWORD: postgres
command: bundle exec rails s -b '0.0.0.0' -p 3000
sidekiq:
build: .
command: bundle exec sidekiq -C /arms_webapp/config/sidekiq.yml
environment: *web-environment
volumes: *web-volumes
depends_on:
- redis
db:
image: postgres:11.4
ports:
- 5432:5432
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
redis:
image: redis:6.2
ports:
- "6379:6379"
volumes:
bundle_cache: