### Helm S3 Plugin and Repository Setup Source: https://context7.com/livekit/livekit-helm/llms.txt Instructions for installing the helm-s3 plugin and adding the LiveKit Helm repository. ```shell # Install the helm-s3 plugin helm plugin install https://github.com/hypnoglow/helm-s3.git # Add the S3 repo as a Helm remote AWS_REGION=us-east-1 helm repo add livekit s3://livekit-helm ``` -------------------------------- ### Install LiveKit Helm Repository and Charts Source: https://context7.com/livekit/livekit-helm/llms.txt Add the LiveKit Helm repository, update it, and install the livekit-server, egress, or ingress charts. Includes an example for upgrading an existing release. ```shell # Add the LiveKit Helm repo helm repo add livekit https://helm.livekit.io helm repo update # Install livekit-server helm install livekit livekit/livekit-server \ --namespace livekit \ --create-namespace \ --values my-values.yaml # Install egress helm install egress livekit/egress \ --namespace livekit \ --values egress-values.yaml # Install ingress helm install ingress livekit/ingress \ --namespace livekit \ --values ingress-values.yaml # Upgrade an existing release helm upgrade livekit livekit/livekit-server \ --namespace livekit \ --values my-values.yaml ``` -------------------------------- ### Install LiveKit Server with Minimal Configuration Source: https://context7.com/livekit/livekit-helm/llms.txt Command to install the livekit-server using Helm with a minimal values file. ```shell helm install livekit livekit/livekit-server \ --namespace livekit --create-namespace \ --values values-minimal.yaml ``` -------------------------------- ### Install LiveKit Server Chart Source: https://github.com/livekit/livekit-helm/blob/master/README.md Install the LiveKit server chart using Helm. Customize installation by specifying values in a values.yaml file. Replace and with your desired values. ```shell helm install livekit/livekit-server --namespace --values values.yaml ``` -------------------------------- ### Install Ingress Helm Chart Source: https://context7.com/livekit/livekit-helm/llms.txt Deploy the LiveKit Ingress service using Helm. Specify the namespace and values file. ```shell helm install ingress livekit/ingress \ --namespace livekit \ --values ingress-sample.yaml ``` -------------------------------- ### Install Egress Helm Chart Source: https://context7.com/livekit/livekit-helm/llms.txt Deploy the LiveKit Egress service using Helm. Ensure the namespace and values file are correctly specified. ```shell helm install egress livekit/egress \ --namespace livekit \ --values egress-sample.yaml ``` -------------------------------- ### Configure Node Scheduling with hostNetwork Source: https://context7.com/livekit/livekit-helm/llms.txt Configure node scheduling for LiveKit when using `podHostNetwork: true`. This setup ensures only one instance runs per physical node and targets specific nodes using `nodeSelector` and `tolerations`. ```yaml podHostNetwork: true # enables hostNetwork + dnsPolicy: ClusterFirstWithHostNet nodeSelector: node.kubernetes.io/instance-type: c5.2xlarge livekit-role: "media" tolerations: - key: "livekit" operator: "Equal" value: "true" effect: "NoSchedule" affinity: podAntiAffinity: requiredDuringSchedulingIgnoredDuringExecution: - labelSelector: matchLabels: app.kubernetes.io/name: livekit-server topologyKey: "kubernetes.io/hostname" ``` -------------------------------- ### Install helm-s3 Plugin and Add S3 Repository Source: https://github.com/livekit/livekit-helm/blob/master/README.md For LiveKit Helm developers, install the helm-s3 plugin to manage charts stored in S3. Then, add the LiveKit S3 repository using your AWS region. ```shell helm plugin install https://github.com/hypnoglow/helm-s3.git AWS_REGION=us-east-1 helm repo add livekit s3://livekit-helm ``` -------------------------------- ### Get Ingress Service Ports Source: https://github.com/livekit/livekit-helm/blob/master/ingress/templates/NOTES.txt View the configured ports for the Ingress service. This is useful for understanding network access points. ```bash kubectl get svc --namespace {{ .Release.Namespace }} {{ template "ingress.fullname" . }} -o jsonpath='{.spec.ports}' ``` -------------------------------- ### Create Kubernetes Secret Manually Source: https://context7.com/livekit/livekit-helm/llms.txt Manually create a Kubernetes Secret for storing API keys before installing the chart, used when referencing an existingSecret. ```shell # Option B: create the secret manually before install kubectl create secret generic my-external-secret \ --namespace livekit \ --from-literal=keys.yaml="myapikey: myapisecret" ``` -------------------------------- ### Get LoadBalancer IP for Ingress Source: https://github.com/livekit/livekit-helm/blob/master/ingress/templates/NOTES.txt Retrieve the external IP address assigned to the Ingress LoadBalancer. This IP is necessary for external access to LiveKit services. ```bash kubectl get svc --namespace {{ .Release.Namespace }} {{ template "ingress.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}' ``` -------------------------------- ### Configure AWS ALB Load Balancer Source: https://context7.com/livekit/livekit-helm/llms.txt Set up an AWS Application Load Balancer (ALB) for LiveKit on EKS. Requires the aws-load-balancer-controller and a pre-existing ACM certificate. ```yaml # examples/server-eks.yaml replicaCount: 2 livekit: rtc: use_external_ip: true redis: address: "redis-host:6379" keys: myapikey: "myapisecret" turn: enabled: true domain: turn.myhost.com tls_port: 3478 secretName: turn-tls-secret loadBalancer: type: alb # uses aws-load-balancer-controller tls: - hosts: - livekit.myhost.com # cert must exist in ACM for auto-discovery autoscaling: enabled: true minReplicas: 1 maxReplicas: 5 targetCPUUtilizationPercentage: 60 resources: limits: cpu: 7500m memory: 2048Mi requests: cpu: 7000m memory: 1024Mi ``` -------------------------------- ### Configure DigitalOcean Load Balancer with cert-manager Source: https://context7.com/livekit/livekit-helm/llms.txt Integrate LiveKit with a DigitalOcean load balancer using cert-manager for automatic TLS certificate provisioning. ```yaml # examples/server-do.yaml loadBalancer: type: do clusterIssuer: letsencrypt-prod tls: - hosts: - livekit.myhost.com secretName: livekit-tls-secret ``` -------------------------------- ### Minimal LiveKit Server Deployment Configuration Source: https://context7.com/livekit/livekit-helm/llms.txt A minimal `values.yaml` configuration for a single-node LiveKit server deployment. Requires Redis coordinates and at least one API key/secret pair. ```yaml # values-minimal.yaml replicaCount: 1 terminationGracePeriodSeconds: 18000 livekit: port: 7880 log_level: info rtc: tcp_port: 7881 port_range_start: 50000 port_range_end: 60000 use_external_ip: true redis: address: "redis-host:6379" db: 0 keys: myapikey: "myapisecret" ``` -------------------------------- ### LiveKit TURN Server Configuration Source: https://context7.com/livekit/livekit-helm/llms.txt Configuration for enabling and setting up an integrated TURN server within livekit-server. Includes options for domain, ports, TLS secrets, and service type. ```yaml livekit: turn: enabled: true domain: turn.myhost.com # must match the TLS certificate CN tls_port: 3478 # TURN/TLS over TCP (set 443 if turnLoadbalancer.enable=false) udp_port: 3478 # TURN/UDP, must be open in firewall secretName: turn-tls-secret # K8s Secret with tls.crt / tls.key serviceType: "LoadBalancer" loadBalancerAnnotations: service.beta.kubernetes.io/aws-load-balancer-type: nlb turnLoadbalancer: enable: true # creates a separate LoadBalancer Service for TURN ``` -------------------------------- ### Core LiveKit Server Configuration Options Source: https://context7.com/livekit/livekit-helm/llms.txt Detailed configuration options for the `livekit:` block, mapping to the livekit-server config schema. This block is rendered into a ConfigMap and passed via `LIVEKIT_CONFIG`. ```yaml livekit: port: 7880 log_level: info # debug | info | warn | error prometheus_port: 6789 # uncomment to expose Prometheus metrics rtc: tcp_port: 7881 port_range_start: 50000 port_range_end: 60000 use_external_ip: true # required when nodes have NAT (cloud VMs) redis: address: "redis-host:6379" db: 0 username: "" password: "" use_tls: false # sentinel_master_name: mymaster # sentinel_addresses: ["sentinel1:26379", "sentinel2:26379"] keys: api_key_1: "api_secret_1" api_key_2: "api_secret_2" room: enabled_codecs: - mime: audio/opus - mime: video/vp8 - mime: video/h264 max_participants: 100 webhook: urls: - "https://myapp.example.com/livekit-webhook" api_key: api_key_1 region: "us-west" # for multi-region deploys ``` -------------------------------- ### Add LiveKit Helm Repository Source: https://github.com/livekit/livekit-helm/blob/master/README.md Add the LiveKit Helm repository to your local Helm configuration. This command fetches the latest chart information. ```shell helm repo add livekit https://helm.livekit.io ``` -------------------------------- ### Configure GKE Standard Load Balancer Source: https://context7.com/livekit/livekit-helm/llms.txt Configure a standard Google Kubernetes Engine (GKE) load balancer for LiveKit. Requires a pre-existing TLS secret. ```yaml # examples/server-gke.yaml loadBalancer: type: gke tls: - hosts: - livekit.myhost.com secretName: livekit-tls-secret ``` -------------------------------- ### Deploy LiveKit Helm Charts Source: https://github.com/livekit/livekit-helm/blob/master/README.md Execute the deploy script to publish LiveKit Helm charts. This script is typically used by developers for deployment. ```shell ./deploy.sh ``` -------------------------------- ### Publishing LiveKit Helm Charts Source: https://context7.com/livekit/livekit-helm/llms.txt Scripts to package and publish LiveKit server, egress, and ingress charts to an S3-backed Helm repository. ```shell # Package and publish livekit-server ./deploy.sh # Package and publish egress ./deploy-egress.sh # Package and publish ingress ./deploy-ingress.sh ``` -------------------------------- ### Ingress Helm Chart Configuration Source: https://context7.com/livekit/livekit-helm/llms.txt Configure the Ingress service for RTMP and WHIP stream ingestion. Includes ports, RTC configuration, and CPU cost settings. ```yaml # ingress-sample.yaml replicaCount: 1 terminationGracePeriodSeconds: 10800 ingress: api_key: "server-api-key" api_secret: "server-api-secret" ws_url: "wss://livekit.myhost.com" logging: level: info health_port: 7888 prometheus_port: 7889 http_relay_port: 9090 rtmp_port: 1935 # RTMP ingest port (e.g., OBS, FFmpeg) whip_port: 8080 # WHIP ingest port (browser-based) rtc_config: use_external_ip: true udp_port: 7885 redis: address: "redis-host:6379" use_tls: false serviceType: "LoadBalancer" cpu_cost: rtmp_cpu_cost: 2.0 whip_cpu_cost: 2.0 whip_bypass_transcoding_cpu_cost: 0.1 # WHIP without transcoding autoscaling: enabled: true minReplicas: 1 maxReplicas: 5 targetCPUUtilizationPercentage: 60 # custom: # metricName: livekit_ingress_available # targetAverageValue: 70 loadBalancer: servicePort: 7888 annotations: service.beta.kubernetes.io/aws-load-balancer-type: nlb ``` -------------------------------- ### Configure GCLB Load Balancer with BackendConfig Source: https://context7.com/livekit/livekit-helm/llms.txt Use Google Cloud Load Balancer (GCLB) with a BackendConfig for LiveKit. This method bypasses Ingress resource creation and allows for advanced configurations like long WebSocket timeouts. ```yaml # gclb-sample.yaml loadBalancer: type: gclb # No Ingress resource is created; configure via BackendConfig gcp: backendConfig: timeoutSec: 36000 # 10-hour WebSocket timeout connectionDraining: drainingTimeoutSec: 60 ``` -------------------------------- ### Configure Prometheus ServiceMonitor Source: https://context7.com/livekit/livekit-helm/llms.txt Create a ServiceMonitor resource for Prometheus Operator to scrape LiveKit metrics. Requires `livekit.prometheus_port` to be set. ```yaml livekit: prometheus_port: 6789 serviceMonitor: create: true interval: 30s annotations: prometheus.io/scrape: "true" ``` -------------------------------- ### Egress with Azure Blob Storage Configuration Source: https://context7.com/livekit/livekit-helm/llms.txt Configure Egress to use Azure Blob Storage for storing recordings. Requires account name, key, and container name. ```yaml egress: api_key: "server-api-key" api_secret: "server-api-secret" ws_url: "wss://livekit.myhost.com" redis: address: "redis-host:6379" azure: account_name: "mystorageaccount" account_key: "base64encodedkey==" container_name: "egress-recordings" ``` -------------------------------- ### Egress Helm Chart Configuration Source: https://context7.com/livekit/livekit-helm/llms.txt Configure the Egress service for recording and streaming. Supports S3, Azure Blob, and GCP Cloud Storage. ```yaml replicaCount: 1 terminationGracePeriodSeconds: 3600 egress: api_key: "server-api-key" api_secret: "server-api-secret" ws_url: "wss://livekit.myhost.com" log_level: info health_port: 8080 prometheus_port: 9090 enable_chrome_sandbox: true # template_base: "https://your-custom-template.com" redis: address: "redis-host:6379" use_tls: false s3: access_key: "AWS_ACCESS_KEY" secret: "AWS_SECRET_KEY" region: "us-west-2" bucket: "my-egress-bucket" # endpoint: "https://s3-compatible.example.com" # for S3-compatible stores autoscaling: enabled: true minReplicas: 1 maxReplicas: 5 targetCPUUtilizationPercentage: 60 # custom: # metricName: livekit_egress_available # built-in Prometheus metric # targetAverageValue: 70 resources: requests: cpu: 5000m memory: 1024Mi limits: cpu: 8000m memory: 2048Mi ``` -------------------------------- ### Configure GKE VPC-Native Load Balancer Source: https://context7.com/livekit/livekit-helm/llms.txt Set up a VPC-native load balancer on GKE for LiveKit. This configuration is suitable for GKE clusters using VPC-native networking. ```yaml # examples/server-gke-vpc-native.yaml loadBalancer: type: gke-vpc-native tls: - hosts: - livekit.myhost.com secretName: livekit-tls-secret ``` -------------------------------- ### LiveKit TURN Server with External TLS Configuration Source: https://context7.com/livekit/livekit-helm/llms.txt Configuration for the TURN server when using externally-managed TLS termination. Disables built-in certificate handling. ```yaml livekit: turn: enabled: true domain: turn.myhost.com tls_port: 443 external_tls: true # disables cert volume mount; no secretName needed ``` -------------------------------- ### Egress with GCP Cloud Storage Configuration Source: https://context7.com/livekit/livekit-helm/llms.txt Configure Egress to use GCP Cloud Storage. Requires credentials JSON and bucket name. ```yaml egress: api_key: "server-api-key" api_secret: "server-api-secret" ws_url: "wss://livekit.myhost.com" redis: address: "redis-host:6379" gcp: credentials_json: | { "type": "service_account", "project_id": "my-project", ... } bucket: "my-egress-bucket" ``` -------------------------------- ### Configure Horizontal Pod Autoscaler Source: https://context7.com/livekit/livekit-helm/llms.txt Enable Horizontal Pod Autoscaler (HPA) for LiveKit to automatically adjust the number of replicas based on resource utilization. Requires resource requests and limits to be defined. ```yaml autoscaling: enabled: true minReplicas: 1 maxReplicas: 10 targetCPUUtilizationPercentage: 60 targetMemoryUtilizationPercentage: 80 resources: # required for HPA to function requests: cpu: 4000m memory: 1024Mi limits: cpu: 6000m memory: 2048Mi ``` -------------------------------- ### Egress CPU Cost Tuning Source: https://context7.com/livekit/livekit-helm/llms.txt Adjust CPU costs for different egress job types to optimize autoscaling decisions. ```yaml egress: cpu_cost: room_composite_cpu_cost: 3 # full-room composite recording track_composite_cpu_cost: 2 # track-composite recording track_cpu_cost: 1 # individual track recording ``` -------------------------------- ### Watch Ingress Service Status Source: https://github.com/livekit/livekit-helm/blob/master/ingress/templates/NOTES.txt Monitor the status of the Ingress service, especially for LoadBalancer IP assignment, which may take a few minutes. ```bash kubectl get svc --namespace {{ .Release.Namespace }} -w {{ template "ingress.fullname" . }} ``` -------------------------------- ### Store API Keys in Kubernetes Secret Source: https://context7.com/livekit/livekit-helm/llms.txt Configure the chart to store API keys in a Kubernetes Secret instead of embedding them directly. This supports creating a new Secret or referencing an existing one. ```yaml livekit: key_file: keys.yaml # path inside the container where keys will be mounted storeKeysInSecret: enabled: true # Option A: let the chart create the Secret keys: myapikey: "myapisecret" # Option B: reference a pre-existing Secret (e.g., managed by Vault) existingSecret: "my-external-secret" ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.