charts

libretranslate

Version: 2.0.0 AppVersion: v1.9.6 Artifact Hub

Warning: breaking change in 2.0.0. Upgrading from a chart version older than 2.0.0 will fail unless you delete the Deployment first. See Upgrading for the exact commands.

Free and Open Source Machine Translation API. Self-hosted, offline capable and easy to setup.

TL;DR

helm repo add obeone https://charts.obeone.cloud
helm repo update
helm install libretranslate obeone/libretranslate

About

LibreTranslate is a free and open source machine translation API powered by Argos Translate. It is fully self-hosted and offline capable: no API keys, no third-party cloud, your text never leaves the cluster. A small web UI ships on top of the REST API for interactive use.

Prerequisites

Configuration

This chart is built on the bjw-s-labs common library. Most configuration keys (controllers, service, ingress, persistence, …) follow its schema; see the common library documentation for everything it supports beyond what is spelled out in values.yaml.

Defaults are meant to work out of the box on any cluster. The full list of options lives in values.yaml, is validated by values.schema.json at install time, and is documented in the Values section below. Override it with your own values file:

helm install libretranslate obeone/libretranslate -f my-values.yaml

Upgrading

Warning If you are upgrading from a chart version older than 2.0.0, helm upgrade will fail: the bjw-s common 5.1.0 migration changes the controller selector label from app.kubernetes.io/component to app.kubernetes.io/controller, and selector labels are immutable on a Kubernetes Deployment. Delete the Deployment first, then upgrade:

kubectl delete deployment <release-name>-libretranslate
helm upgrade <release-name> obeone/libretranslate

This is a plain cascading delete, the default for kubectl delete deployment: the pods go down with it, so expect a short outage while the upgrade recreates them. Do not add --cascade=orphan here. It looks like the safe, zero-downtime option, but the new Deployment selects on app.kubernetes.io/controller, a label the old pods never had, so it can never adopt them. The orphaned pods would keep running unmanaged forever alongside the new ones, and since the models share PVC (<release-name>-share) is ReadWriteOnce, the orphaned pod would keep it attached and the new pod would stay stuck Pending on a multi-attach error. PersistentVolumeClaims (including the models share volume) are not affected by the Deployment delete and must not be deleted separately.

Fresh installs are unaffected; this only applies to upgrades from a pre-2.0.0 release.

helm repo update
helm upgrade libretranslate obeone/libretranslate

Each release lists its changes in the Artifact Hub changelog; give it a look before jumping across several chart versions.

Uninstalling

helm uninstall libretranslate

PersistentVolumeClaims created by the chart are kept around: delete them manually if you also want the data gone.

Requirements

Kubernetes: >=1.31.0-0

Repository Name Version
https://bjw-s-labs.github.io/helm-charts common 5.1.0

Values

Key Type Default Description
additionalVolumeMounts list [] Define additional volumeMounts if needed
additionalVolumes list [] Define additional volumes if needed
affinity object {} Affinity rules to control pod assignment based on node labels
controllers.main.containers.main.env.LT_API_KEYS string "1" Set to “1” to enable API key usage for authentication
controllers.main.containers.main.env.LT_UPDATE_MODELS string "1" Set to “1” to update language models on startup
controllers.main.containers.main.image.pullPolicy string "Always" Image pull policy (Always, IfNotPresent, Never)
controllers.main.containers.main.image.repository string "libretranslate/libretranslate" Image repository to pull
controllers.main.containers.main.image.tag string "v1.9.6" Image tag to pull (use vX.X.X-cuda for GPU builds)
controllers.main.containers.main.probes.liveness.custom bool true  
controllers.main.containers.main.probes.liveness.enabled bool true  
controllers.main.containers.main.probes.liveness.spec.httpGet.path string "/"  
controllers.main.containers.main.probes.liveness.spec.httpGet.port string "http"  
controllers.main.containers.main.probes.readiness.custom bool true  
controllers.main.containers.main.probes.readiness.enabled bool true  
controllers.main.containers.main.probes.readiness.spec.httpGet.path string "/"  
controllers.main.containers.main.probes.readiness.spec.httpGet.port string "http"  
controllers.main.containers.main.resources.limits object {"cpu":"500m","memory":"512Mi"} Resource limits for the main container
controllers.main.containers.main.resources.requests object {"cpu":"100m","memory":"128Mi"} Resource requests for the main container
controllers.main.strategy string "Recreate"  
defaultPodOptions object {"automountServiceAccountToken":false} Pod-wide options applied to every controller in this chart.
defaultPodOptions.automountServiceAccountToken bool false LibreTranslate never talks to the Kubernetes API, so keep the SA token out of the pod.
global object {"gpuEnabled":false} Global parameters for the chart Used to configure GPU support and other global settings
global.gpuEnabled bool false Enable GPU-specific settings (like CUDA paths and GPU resources)
ingress object {"main":{"enabled":false,"hosts":[{"host":"chart-example.local","paths":[{"path":"/","pathType":"Prefix","service":{"identifier":"main","port":"http"}}]}],"tls":[{"hosts":["chart-example.local"],"secretName":"tls-chart-example-local"}]}} Ingress configuration for external access to the service
ingress.main.enabled bool false Enable or disable ingress
ingress.main.tls[0].secretName string "tls-chart-example-local" Secret containing TLS certificate for the ingress
nodeSelector object {} Node selector for pod assignment
persistence object {"api-keys":{"accessMode":"ReadWriteOnce","annotations":{},"enabled":false,"globalMounts":[{"path":"/app/db"}],"size":"10Mi"},"cache":{"enabled":true,"globalMounts":[{"path":"/home/libretranslate/.local/cache"}],"type":"emptyDir"},"db":{"accessMode":"ReadWriteOnce","annotations":{},"enabled":false,"globalMounts":[{"path":"/home/libretranslate/.local/db"}],"size":"1Gi"},"files-translate":{"enabled":true,"globalMounts":[{"path":"/tmp/libretranslate-files-translate"}],"type":"emptyDir"},"share":{"accessMode":"ReadWriteOnce","annotations":{},"enabled":true,"globalMounts":[{"path":"/home/libretranslate/.local/share"}],"size":"20Gi","suffix":"share"}} Persistence volumes configuration for different data types
persistence.api-keys.enabled bool false Enable persistence for API keys database
persistence.cache.enabled bool true Enable temporary cache storage
persistence.db.enabled bool false Enable database storage for application data
persistence.files-translate.enabled bool true Temporary storage for uploaded translation files
persistence.share.enabled bool true Enable persistent shared storage for translation models and shared assets
persistence.share.suffix string "share" Pin the PVC name suffix so it keeps matching pre-5.x installs: common 5.x only appends the identifier when more than one PVC is enabled, which would otherwise rename this PVC and orphan existing translation models.
route object {"main":{"enabled":false,"hostnames":["chart-example.local"],"kind":"HTTPRoute","parentRefs":[{"name":"gateway","namespace":"gateway-system"}],"rules":[{"backendRefs":[{"name":"main"}],"matches":[{"path":{"type":"PathPrefix","value":"/"}}]}]}} Gateway API HTTPRoute, mirroring the Ingress above. Disabled by default: pick either Ingress or HTTPRoute, not both. Requires the Gateway API CRDs and an existing Gateway in the cluster.
route.main.enabled bool false Enable the HTTPRoute. Mutually exclusive with ingress.main.enabled.
route.main.hostnames list ["chart-example.local"] Hostnames served by this route.
route.main.kind string "HTTPRoute" Route kind. HTTPRoute, GRPCRoute, TCPRoute, TLSRoute or UDPRoute.
route.main.parentRefs list [{"name":"gateway","namespace":"gateway-system"}] Gateways this route attaches to.
route.main.rules list [{"backendRefs":[{"name":"main"}],"matches":[{"path":{"type":"PathPrefix","value":"/"}}]}] Routing rules. name resolves to a Service identifier defined above.
service object {"main":{"controller":"main","ports":{"http":{"port":80,"protocol":"TCP","targetPort":5000}}}} Service configuration to expose the application internally in the cluster
service.main.ports.http.port int 80 External service port
service.main.ports.http.protocol string "TCP" Protocol to use (TCP/UDP)
service.main.ports.http.targetPort int 5000 Internal container target port
tolerations list [] Tolerations for pod assignment to specific nodes

Verifying the chart signature

Charts in this repository are signed with GPG and every release ships a provenance file. The public key is available at charts.obeone.cloud/public_key.gpg, fingerprint B9FE852F28888D27F8C9A11CD33E04CD22E335CE.

# Import the signing key into a legacy keyring (helm verifies with GnuPG v1 keyrings)
curl -fsSL https://charts.obeone.cloud/public_key.gpg | gpg --import
gpg --export > ~/.gnupg/pubring.gpg

# Pull the chart and check it against its provenance file
helm pull --verify obeone/libretranslate

Support

This is a personal chart repository, maintained on a best-effort basis. Bug reports and contributions are welcome on GitHub.


Autogenerated from chart metadata using helm-docs v1.14.2