Jump to content

Connect SuperML | Leeroopedia MCP: Equip your AI agents with best practices, code verification, and debugging knowledge. Powered by Leeroo — building Organizational Superintelligence. Contact us at founders@leeroo.com.

Environment:Infiniflow Ragflow Docker Infrastructure

From Leeroopedia
Knowledge Sources
Domains Infrastructure, Deployment
Last Updated 2026-02-12 06:00 GMT

Overview

Docker Compose infrastructure stack with MySQL 8.0, Valkey (Redis) 8, MinIO object storage, Elasticsearch 8.11.3 (or alternative vector DBs), and Nginx reverse proxy.

Description

This environment defines the complete infrastructure layer required for RAGFlow deployment via Docker Compose. It includes six core services: MySQL 8.0.39 for metadata storage, Valkey 8 (Redis-compatible) for task queuing and caching, MinIO for document/file blob storage, a configurable vector database (Elasticsearch 8.11.3, OpenSearch 2.19.1, Infinity 0.7.0-dev2, OceanBase 4.4.1, or SeekDB), and Nginx for reverse proxying. Each service has configurable memory limits, health checks, and persistent volume mounts.

Usage

Use this environment for any RAGFlow deployment whether local development or production. The infrastructure services must be running before the RAGFlow backend server can start. For local development, use `docker compose -f docker/docker-compose-base.yml up -d`.

System Requirements

Category Requirement Notes
OS Any Docker-compatible OS Linux recommended for production
Hardware 16GB+ RAM, multi-core CPU 8GB allocated per container by default (MEM_LIMIT)
Disk 50GB+ SSD Elasticsearch disk watermarks at 5GB/3GB/2GB free
Software Docker Engine + Docker Compose Required for orchestration

Dependencies

Docker Images

  • `mysql:8.0.39` — Relational database (metadata, user data)
  • `valkey/valkey:8` — Redis-compatible cache and task queue
  • `quay.io/minio/minio:RELEASE.2025-06-13T11-33-47Z` — Object storage
  • `elasticsearch:8.11.3` — Default vector/document store
  • `hub.icert.top/opensearchproject/opensearch:2.19.1` — Alternative vector store
  • `infiniflow/infinity:v0.7.0-dev2` — Alternative vector store
  • `oceanbase/oceanbase-ce:4.4.1.0-100000032025101610` — Alternative vector store

Port Assignments

  • MySQL: 3306 (internal), 5455 (exposed)
  • Redis/Valkey: 6379
  • MinIO API: 9000, Console: 9001
  • Elasticsearch: 1200 (remapped from 9200)
  • OpenSearch: 1201
  • Infinity: 23817 (Thrift), 23820 (HTTP), 5432 (PSQL)
  • RAGFlow API: 9380
  • Web HTTP: 80, HTTPS: 443
  • Admin: 9381, MCP: 9382

Credentials

The following credentials are configured in `docker/.env`:

  • `MYSQL_PASSWORD`: MySQL root password (default: "infini_rag_flow").
  • `ELASTIC_PASSWORD`: Elasticsearch password (default: "infini_rag_flow").
  • `OPENSEARCH_PASSWORD`: OpenSearch admin password (default: "infini_rag_flow_OS_01").
  • `MINIO_USER` / `MINIO_PASSWORD`: MinIO access credentials (default: "rag_flow" / "infini_rag_flow").
  • `REDIS_PASSWORD`: Valkey/Redis password (default: "infini_rag_flow").
  • `OCEANBASE_PASSWORD`: OceanBase password (default: "infini_rag_flow").

WARNING: All default passwords must be changed for production deployments.

Quick Install

# Start all infrastructure services
cd docker
docker compose -f docker-compose-base.yml up -d

# Start full stack (infrastructure + RAGFlow)
docker compose -f docker-compose.yml up -d

# Check service health
docker compose -f docker-compose-base.yml ps

Code Evidence

Elasticsearch disk watermark configuration from `docker/docker-compose-base.yml:19-21`:

cluster.routing.allocation.disk.watermark.low=5gb
cluster.routing.allocation.disk.watermark.high=3gb
cluster.routing.allocation.disk.watermark.flood_stage=2gb

MySQL configuration from `docker/docker-compose-base.yml:183-189`:

command: >
  --max_connections=1000
  --character-set-server=utf8mb4
  --default-authentication-plugin=mysql_native_password
  --tls_version="TLSv1.2,TLSv1.3"
  --binlog_expire_logs_seconds=604800

Redis/Valkey memory limit from `docker/docker-compose-base.yml:228`:

command: ["valkey-server", "--maxmemory", "128mb", "--maxmemory-policy", "allkeys-lru",
          "--requirepass", "${REDIS_PASSWORD}"]

Container memory limit from `docker/.env:65`:

MEM_LIMIT=8073741824  # ~8GB per container

Common Errors

Error Message Cause Solution
Elasticsearch `flood_stage` disk watermark exceeded Less than 2GB free disk Free disk space or increase `flood_stage` watermark
MySQL `max_connections` exceeded More than 1000 concurrent connections Increase `max_connections` in compose config
MinIO connection refused on port 9000 MinIO container not healthy Check `docker logs minio` and ensure volume is writable
Redis `OOM command not allowed` Exceeded 128MB memory limit Increase `--maxmemory` in Valkey command

Compatibility Notes

  • DOC_ENGINE selection: Set `DOC_ENGINE=elasticsearch` (default), `infinity`, `oceanbase`, `opensearch`, or `seekdb` in `docker/.env`.
  • GPU support: Use `DEVICE=gpu` and Docker Compose `ragflow-gpu` profile for NVIDIA GPU passthrough.
  • OceanBase memory: Requires minimum 10GB memory (`OB_MEMORY_LIMIT`), 2GB system memory, 20GB datafile, 20GB log disk.
  • Nginx: Max upload body size is 1024MB (`client_max_body_size`). Proxy read/send timeout is 3600s.

Related Pages

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment