Skip to content

lmnr-ai/lmnr-helm

Repository files navigation

Laminar Helm Chart

Deploy Laminar on Kubernetes with a single command.

What's Included

  • Frontend - Web application with ALB ingress
  • App Server - Backend API with NLB for gRPC/HTTP
  • PostgreSQL - Database for metadata (StatefulSet with persistence)
  • ClickHouse - Primary database for user data (StatefulSet with persistence)
  • Redis - Cache and session store
  • RabbitMQ - Message queue (StatefulSet with persistence)
  • Quickwit - Full-text search engine

Quick Start

First, either clone this repository and cd into the directory or add it to helm directly.

helm repo add laminar https://github.com/lmnr-ai/lmnr-helm
helm repo update

Then, follow the steps below to install Laminar.

# 1. Customize laminar.yaml with your cloud provider ("aws" or "gcp"), credentials, and storage buckets

# 2. Install
helm upgrade -i laminar . -f laminar.yaml

# 3. Get ALB URL (wait 1-2 minutes for provisioning)
ALB_URL=$(kubectl get ingress laminar-frontend-alb -o jsonpath='{.status.loadBalancer.ingress[0].hostname}')

# 4. Configure frontend URLs
helm upgrade -i laminar . -f laminar.yaml \
  --set frontend.env.nextauthUrl="http://$ALB_URL" \
  --set frontend.env.nextPublicUrl="http://$ALB_URL"

# 5. Get the LMNR_BASE_URL (to send traces to)
LMNR_BASE_URL=$(kubectl get svc laminar-app-server-load-balancer -o jsonpath='{.status.loadBalancer.ingress[0].hostname}') && echo $LMNR_BASE_URL

See QUICKSTART.md for detailed installation steps.

Architecture

┌─────────────────────────────────────────────────────────────────┐
│                         External Traffic                        │
├─────────────────────────────────────────────────────────────────┤
│                                                                 │
│    ┌──────────────┐                    ┌──────────────┐         │
│    │   AWS ALB    │                    │   AWS NLB    │         │
│    │  (HTTP/S)    │                    │ (gRPC/HTTP)  │         │
│    └──────┬───────┘                    └──────┬───────┘         │
│           │                                   │                 │
│           ▼                                   ▼                 │
│    ┌──────────────┐                    ┌──────────────┐         │
│    │   Frontend   │───────────────────▶│  App Server  │         │
│    │   (Next.js)  │                    │   (Rust)     │         │
│    └──────┬───────┘                    └──────┬───────┘         │
│           │                                   │                 │
├───────────┼───────────────────────────────────┼─────────────────┤
│           │           Internal Services       │                 │
│           │                                   │                 │
│    ┌──────┴───────────────────────────────────┴──────┐          │
│    │                                                 │          │
│    ▼                  ▼                ▼             ▼          │
│ ┌──────┐        ┌──────────┐      ┌──────────┐  ┌──────────┐    │
│ │Redis │        │PostgreSQL│      │ClickHouse│  │ RabbitMQ │    │
│ └──────┘        └──────────┘      └──────────┘  └──────────┘    │
│                                                                 │
│                        ┌──────────┐                             │
│                        │ Quickwit │                             │
│                        └──────────┘                             │
└─────────────────────────────────────────────────────────────────┘

Prerequisites

Note on Namespaces: By default, all resources are created in the default namespace. Advanced users who prefer a custom namespace (e.g., laminar) should add --namespace laminar --create-namespace to helm commands and -n laminar to kubectl commands.

Configuration

Configuration Files

  • laminar.yaml - Your custom configuration (edit this)
  • values.yaml - Base defaults (don't edit, use for reference)

Helm merges both files, with laminar.yaml taking precedence.

Minimal Configuration

Edit laminar.yaml and set:

  1. Cloud Provider: Set global.cloudProvider to aws or gcp
  2. Cloud credentials and S3 buckets for trace storage
  3. ClickHouse S3 bucket endpoint and region
  4. Availability zones (Required for AWS EBS volumes)
  5. Frontend URLs (can be set after initial deployment)
secrets:
  data:
    AWS_ACCESS_KEY_ID: "your-key"
    AWS_SECRET_ACCESS_KEY: "your-secret"
    NEXTAUTH_SECRET: "random-secret-string"

clickhouse:
  s3:
    endpoint: "https://your-bucket.s3.us-east-1.amazonaws.com/"
    region: "us-east-1"

storage:
  zones:
    - "us-east-1b" # Required for AWS EBS, can be empty for GCP

Production Configuration

For production deployments, additionally configure:

  1. OAuth Configuration for logging in to the UI platform. Google and Github are supported.
  2. Secure passwords for PostgreSQL, ClickHouse, and RabbitMQ (in secrets.data)
  3. External secret management (AWS Secrets Manager or HashiCorp Vault)
  4. HTTPS with an ACM certificate
  5. Custom domain with external-dns

See CONFIGURATION.md for complete configuration reference.

Common Operations

Check Status

kubectl get pods
kubectl get svc
kubectl get ingress

View Logs

kubectl logs -l app=laminar-frontend -f
kubectl logs -l app=laminar-app-server -f

Access Databases

# PostgreSQL
kubectl exec -it laminar-postgres-0 -- psql -U lmnr -d lmnr

# ClickHouse
kubectl exec -it laminar-clickhouse-0 -- clickhouse-client

Upgrade

helm upgrade -i laminar . -f laminar.yaml

Uninstall

helm uninstall laminar

# To also delete persistent data:
kubectl delete pvc -l app=laminar-postgres
kubectl delete pvc -l app=laminar-clickhouse
kubectl delete pvc -l app=laminar-rabbitmq

Documentation

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors