Install on Kubernetes
Install the platform with the Helm chart.
You can run mlflow on a Kubernetes cluster with the Helm chart that comes with your installation package. The chart deploys the API, the workers, the web app, and, if you want, PostgreSQL and Redis inside the cluster. This page walks you through an installation and explains the settings that matter.
Test in a staging cluster first
The chart is a starting point for operators who know Kubernetes. It has not been verified against every cluster setup. Install it in a staging namespace and test sign-in, a training run, a deployment and a backup restore before you use it for production. If you want the shortest supported path, use the Docker installer on one server.
Requirements
- A Kubernetes cluster and
kubectlandhelm(version 3) on your computer. - An ingress controller (the chart defaults to the class
nginx) and, for automatic certificates, cert-manager with a cluster issuer. - A DNS name for the app, for example
app.example.com, that points to the ingress. - S3-compatible object storage (a bucket, its endpoint and an access key and secret key). Trained models and datasets are stored there. The chart does not support a local volume shared between the API and the workers.
- The container images of mlflow, from the package or registry you received: one for the API and workers, one for the web app.
- PostgreSQL and Redis. The chart can run both inside the cluster (the default), or you can point it at managed services such as a cloud database.
A small installation fits on three nodes with 16 GB of memory each. The chart's defaults are sized for that.
Install the chart
Create the namespace and the secrets
The chart reads its secrets from Kubernetes secrets that you create first. By default it expects these names and keys:
kubectl create namespace mlflow
# Signs session tokens. Use a long random value.
kubectl -n mlflow create secret generic pycaret-jwt \
--from-literal=secret="$(openssl rand -base64 48)"
# Encrypts stored secrets (database passwords, AI provider keys, webhook secrets).
kubectl -n mlflow create secret generic pycaret-encryption \
--from-literal=key="$(openssl rand -base64 32)"
# Password of the PostgreSQL that the chart creates.
kubectl -n mlflow create secret generic pycaret-postgres \
--from-literal=password="$(openssl rand -base64 24)"
# Access to your object storage.
kubectl -n mlflow create secret generic mlflow-s3 \
--from-literal=accessKey="<access key>" --from-literal=secretKey="<secret key>"Keep a copy of the encryption key outside the cluster. Without it, stored secrets cannot be read after a restore. See Backups and upgrades.
Write your values file
Create values-mine.yaml with your settings. This is a typical example:
fullnameOverride: mlflow
global:
imageTag: "<version>"
domain: app.example.com
api:
image:
repository: <registry>/<api image>
web:
image:
repository: <registry>/<web image>
worker:
image:
repository: <registry>/<api image>
externalS3:
endpoint: https://s3.eu-west-1.amazonaws.com
bucket: <your bucket>
region: eu-west-1
credentialsSecretRef:
name: mlflow-s3fullnameOverride: mlflow gives short resource names such as mlflow-api and mlflow-postgres, which the commands on these pages use.
Install
helm install mlflow <path to the chart> -n mlflow -f values-mine.yamlRun the database migrations
On a new PostgreSQL database the API does not start until the schema exists, so its pods restart until you do this. Run the migration once with the same image and the same database settings as the API, for example as a one-off job or pod, using the command pycaret-server migrate. When it finishes, the API pods become ready. For later upgrades, see Backups and upgrades.
Create the first account
Open https://app.example.com. On a new installation the app asks you to create the first administrator account. After that, create your workspaces and invite people. See Sign in and your account.
Check the state of the installation any time:
kubectl -n mlflow get pods
kubectl -n mlflow exec deploy/mlflow-api -- pycaret-server doctorThe doctor command checks the database, Redis and the artifact storage.
Values that matter
| Value | Default | What it does |
|---|---|---|
global.imageTag | the chart's version | The version of the API and worker images. Change it to upgrade. |
global.domain | pycaret.local | The app's host name. It is used for the ingress, for allowed browser origins and for links in emails. Always set it. |
global.siteDomain | empty | Optional host for a public landing page. Used only with site.enabled. |
api.replicaCount | 2 | Number of API pods. |
worker.replicaCount | 2 | Number of worker pods. Workers run the training jobs. |
worker.queues | default,cpu-heavy | Which job queues the workers read. Add a separate release with gpu for a GPU node pool. |
web.replicaCount | 2 | Number of web pods. |
postgres.enabled | true | Run PostgreSQL in the cluster. Set false and fill externalPostgres.url to use a managed database. |
postgres.persistence.size | 20Gi | Disk for the in-cluster database. |
redis.enabled | true | Run Redis in the cluster, for the job queue and live updates. Set false and fill externalRedis.url to use your own. |
externalS3.* | empty | Endpoint, bucket, region and credentials of the object storage. Required. |
api.env | production defaults | Extra environment variables for the API. See Configuration. |
api.resources, worker.resources | 250m to 1 CPU and 0.5 to 1 GiB for the API, 0.5 to 2 CPU and 1 to 4 GiB for workers | Raise the worker limits for large datasets. |
observability.podDisruptionBudget.enabled | true | Keeps at least one pod during maintenance of nodes. |
The in-cluster PostgreSQL and Redis are single instances without replication. For a production installation, use managed services for both, and back them up.
Health checks use two addresses of the API: /healthz tells Kubernetes whether the process is alive, and /readyz whether the database is reachable. A pod that cannot reach the database receives no traffic.
Ingress and TLS
The chart creates an ingress with these routes on the app host:
/apigoes to the API./goes to the web app.
With the default settings it uses the class nginx, asks cert-manager for a certificate through the issuer letsencrypt-prod and stores it in the secret pycaret-tls. To use other values:
ingress:
className: nginx
hostname: app.example.com # defaults to global.domain
annotations:
cert-manager.io/cluster-issuer: my-issuer
tls:
enabled: true
secretName: mlflow-tlsThe rate limiter and the audit log use the client's address. Make sure your ingress passes the real address in X-Forwarded-For, and read Domains and TLS for the settings that tell the API how many proxies sit in front of it. The training progress screen needs long-lived connections, so do not set a short timeout on the /api route.
Upgrades
To upgrade, back up the database and the artifacts, change global.imageTag, run helm upgrade, and apply the migrations. The exact steps, the order of the workers and the rollback are on Backups and upgrades.
helm upgrade mlflow <path to the chart> -n mlflow -f values-mine.yaml --set global.imageTag=<new version>Related
Updated 2026-11-22