version: '3.8'

services:

  django:
    build: .
    command: python manage.py runserver 0.0.0.0:8000
    container_name: django
    volumes:
      - .:/steering
    expose:
      - "8000"
    ports:
      - "8000:8000"
    depends_on:
      - postgres
    environment:
      - DEBUG=True
      - SECRET_KEY=foo
      - POSTGRES_PASSWORD=aura

  postgres:
    image: postgres:13.5-bullseye
    container_name: steering-postgres
    volumes:
      - postgres_data:/var/lib/postgresql/data
    environment:
      - POSTGRES_USER=steering
      - POSTGRES_PASSWORD=aura
      - POSTGRES_DB=steering
    expose:
      - "5432"

volumes:
  postgres_data:
