2018-09-03 21:08:32 +00:00
|
|
|
version: '2'
|
|
|
|
|
|
|
|
services:
|
|
|
|
app:
|
|
|
|
build: .
|
2018-09-04 10:12:17 +00:00
|
|
|
image: carnetdejeu
|
2018-09-03 21:08:32 +00:00
|
|
|
command: amber watch
|
|
|
|
environment:
|
2018-09-04 10:12:17 +00:00
|
|
|
DATABASE_URL: postgres://admin:password@db:5432/carnetdejeu_development
|
2018-09-03 21:08:32 +00:00
|
|
|
ports:
|
|
|
|
- 3000:3000
|
|
|
|
links:
|
|
|
|
- db
|
|
|
|
volumes:
|
|
|
|
- .:/app
|
|
|
|
- nodes:/app/node_modules
|
|
|
|
- shards:/app/lib
|
|
|
|
|
|
|
|
migrate:
|
|
|
|
build: .
|
2018-09-04 10:12:17 +00:00
|
|
|
image: carnetdejeu
|
2018-09-03 21:08:32 +00:00
|
|
|
command: bash -c 'while ! nc -q 1 db 5432 </dev/null; do sleep 1; done && amber db migrate seed'
|
|
|
|
environment:
|
2018-09-04 10:12:17 +00:00
|
|
|
DATABASE_URL: postgres://admin:password@db:5432/carnetdejeu_development
|
2018-09-03 21:08:32 +00:00
|
|
|
volumes:
|
|
|
|
- .:/app
|
|
|
|
links:
|
|
|
|
- db
|
|
|
|
|
|
|
|
db:
|
|
|
|
image: postgres
|
|
|
|
environment:
|
|
|
|
POSTGRES_USER: admin
|
|
|
|
POSTGRES_PASSWORD: password
|
2018-09-04 10:12:17 +00:00
|
|
|
POSTGRES_DB: carnetdejeu_development
|
2018-09-03 21:08:32 +00:00
|
|
|
volumes:
|
|
|
|
- db:/var/lib/postgres/data
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
db:
|
|
|
|
nodes:
|
|
|
|
shards:
|