services: postgres: image: pgvector/pgvector:pg17 container_name: braincore-pgvector environment: POSTGRES_USER: braincore POSTGRES_PASSWORD: braincore_dev_pass POSTGRES_DB: braincore_memory ports: - "5432:5432" volumes: - pgdata:/var/lib/postgresql/data - ./sql/001_init.sql:/docker-entrypoint-initdb.d/001_init.sql:ro - ./sql/002_seed.sql:/docker-entrypoint-initdb.d/002_seed.sql:ro healthcheck: test: ["CMD-SHELL", "pg_isready -U braincore -d braincore_memory"] interval: 5s timeout: 5s retries: 5 networks: - braincore # Optional: run the FastAPI app in Docker too. # Uncomment after building the image or use local uvicorn for dev. # api: # build: . # container_name: braincore-api # ports: # - "8000:8000" # environment: # - DATABASE_URL=postgresql://braincore:braincore_dev_pass@postgres:5432/braincore_memory # depends_on: # postgres: # condition: service_healthy # networks: # - braincore volumes: pgdata: networks: braincore: driver: bridge