Update to rails 6.0.3.7
[rails.git] / docker-compose.yml
1 version: "3"
2
3 services:
4   web:
5     build:
6       context: .
7     volumes:
8       - .:/app
9       # Prevent these directories from mounting so they're not shared between host OS and Docker
10       - /app/node_modules/
11       - /app/tmp/
12       # Mount these upload directories so they persist between runs
13       - web-traces:/home/osm/traces
14       - web-images:/home/osm/images
15     ports:
16       - "3000:3000"
17     command: bundle exec rails s -p 3000 -b '0.0.0.0'
18     depends_on:
19       - db
20
21   db:
22     build:
23       context: .
24       dockerfile: docker/postgres/Dockerfile
25     ports:
26       - "54321:5432"
27     environment:
28       POSTGRES_HOST_AUTH_METHOD: trust
29       POSTGRES_DB: openstreetmap
30     volumes:
31       # Mount the Postgres data directory so it persists between runs
32       - db-data:/var/lib/postgresql/data
33
34 volumes:
35   web-traces:
36   web-images:
37   db-data: