services: postgres: image: postgres:16-alpine environment: POSTGRES_USER: gearbox POSTGRES_PASSWORD: gearbox POSTGRES_DB: gearbox ports: - "5432:5432" volumes: - pgdata-dev:/var/lib/postgresql/data - ./docker/init-logto-db.sql:/docker-entrypoint-initdb.d/init-logto-db.sql healthcheck: test: ["CMD-SHELL", "pg_isready -U gearbox"] interval: 5s timeout: 3s retries: 5 logto: image: svhd/logto:latest depends_on: postgres: condition: service_healthy entrypoint: ["sh", "-c", "npm run cli db seed -- --swe && npm start"] ports: - "3001:3001" - "3002:3002" environment: TRUST_PROXY_HEADER: "1" DB_URL: postgres://gearbox:gearbox@postgres:5432/logto ENDPOINT: ${LOGTO_ENDPOINT:-http://localhost:3001} ADMIN_ENDPOINT: ${LOGTO_ADMIN_ENDPOINT:-http://localhost:3002} # MinIO S3-compatible object storage for image uploads. # Note: MinIO GitHub repo archived Feb 2026. The S3 API abstraction in # storage.service.ts makes the provider swappable (SeaweedFS, Garage, AWS S3). minio: image: quay.io/minio/minio:RELEASE.2025-09-07T16-13-09Z command: server /data --console-address ":9001" environment: MINIO_ROOT_USER: minioadmin MINIO_ROOT_PASSWORD: minioadmin ports: - "9000:9000" - "9001:9001" volumes: - minio-data-dev:/data healthcheck: test: ["CMD", "mc", "ready", "local"] interval: 5s timeout: 3s retries: 5 minio-init: image: quay.io/minio/mc:latest depends_on: minio: condition: service_healthy entrypoint: > /bin/sh -c " mc alias set myminio http://minio:9000 minioadmin minioadmin; mc mb --ignore-existing myminio/gearbox-images; exit 0; " volumes: pgdata-dev: minio-data-dev: