-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
31 lines (31 loc) · 1 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
version: "3.9"
services:
db:
image: postgres
volumes:
- ./tmp/db:/var/lib/postgresql/data:rw
- ./scripts:/opt/scripts
environment:
POSTGRES_PASSWORD: "${RAILS_DB_PASSWORD:-thisisprobablyabadidea!}"
POSTGRES_USER: "${RAILS_DB_USER:-classifyr}"
command: /opt/scripts/initdb.sh
web:
build: .
command: bash -c "rm -f tmp/pids/server.pid && bundle install && bundle exec rails s -p 3000 -b '0.0.0.0'"
volumes:
- .:/opt/classifyr
ports:
- "3000:3000"
environment:
RAILS_DB_HOST: db
RAILS_DB_PASSWORD: "${RAILS_DB_PASSWORD:-thisisprobablyabadidea!}"
RAILS_DB_USER: "${RAILS_DB_USER:-classifyr}"
AWS_ACCESS_KEY_ID: "${AWS_ACCESS_KEY_ID}"
AWS_SECRET_ACCESS_KEY: "${AWS_SECRET_ACCESS_KEY}"
AWS_SESSION_TOKEN: "${AWS_SESSION_TOKEN}"
AWS_REGION: "${AWS_REGION:-us-east-1}"
# Our container has no browser, so we can't use letter opener.
LAUNCHY_DRY_RUN: true
BROWSER: /dev/null
depends_on:
- db