Mjara Docs
Deployment

Deployment Overview

Deployment options and production setup for the RAG system

Deployment Overview

The RAG system supports multiple deployment configurations, from local development to production Docker containers.

Deployment Architecture

Deployment Options

Option 1 — Local Development

Run the API server directly with Python:

# Activate virtual environment
source .venv/bin/activate

# Start the server
uvicorn api.main:app --reload --host 0.0.0.0 --port 9000

Requirements:

  • Python 3.10+ with dependencies installed
  • Ollama running locally or remotely
  • PostgreSQL accessible

Deploy with Docker Compose:

docker compose up -d api

The container connects to external services (Ollama, TEI, PostgreSQL) running on the host via host.docker.internal.

See Docker Deployment for full configuration.

Option 3 — Kubernetes

Kubernetes manifests are available in .kubernates/ for orchestrated deployment.

Production Checklist

ItemDescription
API KeysSet strong API_KEYS in .env
CORSRestrict API_CORS_ORIGINS to your domain
DatabaseUse a managed PostgreSQL/Supabase instance
OllamaDeploy on a GPU server for best performance
MonitoringEnable health checks at /api/v1/health/ready
LoggingLogs are written to logs/ directory
BackupsBack up ChromaDB data/chroma_db/ and PostgreSQL
WorkersUse multiple Uvicorn workers (--workers 2 default in Docker)

On this page