carnetdejeu-crystal/docker-compose.yml

43 lines
840 B
YAML
Raw Permalink Normal View History

2018-09-03 21:08:32 +00:00
version: '2'
services:
app:
build: .
image: carnetdejeu
2018-09-03 21:08:32 +00:00
command: amber watch
environment:
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: .
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:
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
POSTGRES_DB: carnetdejeu_development
2018-09-03 21:08:32 +00:00
volumes:
- db:/var/lib/postgres/data
volumes:
db:
nodes:
shards: