name: rustbox services: postgres: image: postgres:17-trixie environment: POSTGRES_DB: rustbox POSTGRES_USER: rustbox POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-rustbox-dev-password} healthcheck: test: ["CMD-SHELL", "pg_isready -U rustbox -d rustbox"] interval: 5s timeout: 5s retries: 20 volumes: - postgres-data:/var/lib/postgresql/data s3: image: docker.io/pgsty/silo:RELEASE.2026-10-26T00-00-00Z command: server /data --console-address :9001 environment: MINIO_ROOT_USER: ${S3_ACCESS_KEY:-rustbox} MINIO_ROOT_PASSWORD: ${S3_SECRET_KEY:-rustbox-s3-dev-password} healthcheck: test: ["CMD", "silo", "healthcheck", "ready"] interval: 5s timeout: 5s retries: 30 volumes: - s3-data:/data s3-init: image: docker.io/pgsty/mc:RELEASE.2026-10-26T00-00-00Z depends_on: s3: condition: service_healthy environment: MC_HOST_local: http://${S3_ACCESS_KEY:-rustbox}:${S3_SECRET_KEY:-rustbox-s3-dev-password}@s3:9000 command: ["mb", "--ignore-existing", "local/rustbox"] opensearch: image: opensearchproject/opensearch:3.9.0 environment: discovery.type: single-node DISABLE_INSTALL_DEMO_CONFIG: "true" DISABLE_SECURITY_PLUGIN: "true" OPENSEARCH_JAVA_OPTS: -Xms512m -Xmx512m healthcheck: test: ["CMD-SHELL", "curl -fsS http://localhost:9200/_cluster/health >/dev/null || exit 1"] interval: 10s timeout: 5s retries: 30 volumes: - opensearch-data:/usr/share/opensearch/data rustbox: build: context: .. dockerfile: docker/Dockerfile depends_on: postgres: condition: service_healthy s3-init: condition: service_completed_successfully opensearch: condition: service_healthy ports: - "${PORT:-3001}:${PORT:-3001}" environment: RUSTBOX_CONFIG: /etc/rustbox/rustbox.toml ENVIRONMENT: ${ENVIRONMENT:-development} HOST: ${HOST:-0.0.0.0} PORT: ${PORT:-3001} IMAP_HOST: ${IMAP_HOST:-mail.example.com} IMAP_PORT: ${IMAP_PORT:-993} SMTP_HOST: ${SMTP_HOST:-mail.example.com} SMTP_PORT: ${SMTP_PORT:-587} TLS_ENABLED: ${TLS_ENABLED:-true} RUST_LOG: ${RUST_LOG:-warn,rustbox=info,tower_http=info} DATABASE_URL: postgres://rustbox:${POSTGRES_PASSWORD:-rustbox-dev-password}@postgres:5432/rustbox SESSION_ENCRYPTION_KEY: ${SESSION_ENCRYPTION_KEY:-MDEyMzQ1Njc4OWFiY2RlZjAxMjM0NTY3ODlhYmNkZWY=} AWS_ACCESS_KEY_ID: ${S3_ACCESS_KEY:-rustbox} AWS_SECRET_ACCESS_KEY: ${S3_SECRET_KEY:-rustbox-s3-dev-password} volumes: - ./configs/postgres-s3-opensearch.toml:/etc/rustbox/rustbox.toml:ro restart: unless-stopped volumes: postgres-data: s3-data: opensearch-data: