martin/docker-compose.yml
2018-10-15 19:39:45 +03:00

32 lines
690 B
YAML

version: '3.7'
services:
nginx:
build:
context: .
dockerfile: front.Dockerfile
restart: unless-stopped
depends_on:
- martin
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf
martin:
image: urbica/martin
restart: unless-stopped
environment:
- DATABASE_URL=postgres://postgres:postgres@db/db
depends_on:
- db
db:
build:
context: .
dockerfile: db.Dockerfile
restart: unless-stopped
environment:
- POSTGRES_DB=db
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
volumes:
- ./db:/var/lib/postgresql/data
- ./docker-entrypoint-initdb:/docker-entrypoint-initdb.d