version: '3.8'
name: fids-flights-dev

services:
  flights-api:
    extends:
      file: docker-template.yml
      service: flights-api
    container_name: fids-flights-dev_flights-api
    environment:
      - DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASS}@flights-db/${POSTGRES_DB}
    depends_on:
      flights-db:
        condition: service_healthy
    networks:
      - flights
      - subscriptions
    logging:
      options:
        tag: dev-flights

  flights-db:
    extends:
      file: docker-template.yml
      service: flights-db
    container_name: fids-flights-dev_flights-db
    networks:
      - flights

networks:
  subscriptions:
    name: fids-subs-dev_subscriptions
    external: true
  flights:
    driver: bridge