
services:
  eddi:
    image: labsai/eddi:latest
    ports:
      - "7070:7070"
    environment:
      QUARKUS_PROFILE: postgres
      QUARKUS_DATASOURCE_JDBC_URL: jdbc:postgresql://postgres:5432/eddi
      QUARKUS_DATASOURCE_USERNAME: eddi
      QUARKUS_DATASOURCE_PASSWORD: eddi
      EDDI_DATASTORE_TYPE: postgres
      EDDI_SECURITY_ALLOW_UNAUTHENTICATED: "true"
      EDDI_VAULT_MASTER_KEY: "${EDDI_VAULT_MASTER_KEY:-}"
    depends_on:
      postgres:
        condition: service_healthy

  postgres:
    image: postgres:16-alpine
    ports:
      - "5432:5432"
    environment:
      POSTGRES_DB: eddi
      POSTGRES_USER: eddi
      POSTGRES_PASSWORD: eddi
    volumes:
      - pgdata:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U eddi -d eddi"]
      interval: 5s
      timeout: 3s
      retries: 5

volumes:
  pgdata:

