Kubernetes Deployment
Memanto is a single-binary FastAPI app — there are no leader-election, sticky-session, or shared-volume concerns. The deployment manifests below are intentionally minimal; adapt the resources, security context, and ingress to fit your cluster. The manifests use the cloud backend by default. The “On-Prem Backend” section at the bottom shows how to add the Moorcheh server (and optionally Ollama) as sibling pods.Deployment
/ready is the right liveness probe because it always returns 200 once the process is up — using /health would restart pods every time Moorcheh has a hiccup. /health is the right readiness probe because it gates traffic on actual Moorcheh connectivity.
Service
Secret
Ingress (TLS Termination)
Horizontal Pod Autoscaler
Memanto is I/O-bound, so scale on CPU:On-Prem Backend on Kubernetes
To run Moorcheh inside the same cluster as Memanto, add a Moorcheh deployment and pointMOORCHEH_ONPREM_URL at the in-cluster Service.
ConfigMap for the embedding / LLM block (replace with your provider of choice):
Secret + an init container or external-secrets operator instead of embedding them in the ConfigMap.
Then update the Memanto Deployment env block to point at the in-cluster Moorcheh:
MOORCHEH_API_KEY env var when on-prem — it isn’t consulted in on-prem mode.
Ollama on Kubernetes (Optional)
If you want fully local inference, add an Ollama Deployment with persistent storage for model weights:"base_url": "http://ollama:11434" for both embedding and LLM blocks.
After deploy, pull your models once:
NetworkPolicy (Recommended)
Restrict who can reach Memanto and Moorcheh:Applying
Cloud Platform Quick-Reference
The Memanto image is generic — it runs anywhere that can host a container.
For on-prem on managed platforms, the Moorcheh container needs persistent storage and an internal endpoint your Memanto service can reach — most platforms make this straightforward via “sidecar” or “internal service” features.