Kubeflow is an open-source platform for Machine Learning and MLOps on Kubernetes introduced by Google. The different stages in a typical machine learning lifecycle are represented with different software components in Kubeflow, including model development, model training, model serving, and automated machine learning.

ToolDescription
ArenaA CLI for Kubeflow
RomarioRESTful API for kick-starting a KF-Pipeline
Training-operatorTraining operators on Kubernetes
KatibRepository for hyperparameter tuning
FairingPython SDK for building, training, and deploying ML models
KServeStandardized Serverless ML Inference Platform on Kubernetes
KaleKubeflow’s superfood for Data Scientists
BentoMLUnified Model Serving Framework
YataiModel Deployment at Scale on Kubernetes
Bootstrap🪐 1-click Kubeflow using ArgoCD

Articles/Talks

Main components

Authentication

Kubeflow use ambasador-oidc call oidc-authservice as an authentication service with an HTTP Server in combination with Dex as OIDC provider.

Centraldashboard

The Kubeflow Central Dashboard provides an authenticated web interface for Kubeflow and ecosystem components. It acts as a hub for your machine learning platform and tools by exposing the UIs of components running in the cluster. Access through the Istio Gateway that provides access to the Kubeflow.

Notebook

Kubeflow Notebooks provides a way to run web-based development environments inside your Kubernetes cluster by running them inside Pods. Support Jupyter and VSCode.

Kubeflow use these services for deploy and control notebooks:

  • jupyter-web-app-deployment
  • volumes-web-app-deployment
  • notebook-controller-deployment

Deactivate secure cookies if TLS is not configured.

# change in kubernetes templates
APP_SECURE_COOKIES = false

Metadata

Kubeflow Pipelines backend stores runtime information of a pipeline run in Metadata store. Runtime information includes the status of a task, availability of artifacts, custom properties associated with Execution or Artifact, etc. Learn more at ML Metadatafor using google/ml-metadata.

Kubeflow use these services:

  • MySQL - store metadata
  • metadata-envoy-deployment - envoy proxy
  • metadata-grpc-deployment - allows other components to interact with the metadata service
  • metadata-writer - comprehensive record of the entire machine learning lifecycle

Pipelines

Cache

The cache server is a key-value storage system that store frequently accessed ML artifacts, such as trained models and intermediate results.

  • cache-server

Admission webhook

We need a way to inject common data (env vars, volumes) to pods (e.g. notebooks). PodPreset implementation, customize it for Kubeflow and rename it to PodDefault to avoid confusion. Use admision webhook and CRD to implement the functionality.

  • admission-webhook-deployment

PVCViewer

Use filebrowser for provide a file managing interface within a specified directory.

Metacontroller

Use metacontroller as an add-on for Kubernetes that makes it easy to write and deploy custom resources

Istio

KServe

Add SSL

  • Create certificate
kubectl create -n knative-serving secret tls custom-certs --key registry.key --cert registry.crt
  • Edit deployment knative-serving
apiVersion: apps/v1  
kind: Deployment  
metadata:  
  name: controller  
  namespace: knative-serving  
spec:  
  template:  
    spec:  
      containers:  
        - name: controller  
          volumeMounts:  
            - name: custom-certs  
              mountPath: /path-to-docker-registry-cert  # replace here.  
          env:  
            - name: SSL_CERT_FILE  
              value: /path-to-docker-registry-cert # replace here.  
            - name: GODEBUG  
              value: x509ignoreCN=0  
      volumes:  
        - name: custom-certs  
          secret:  
            secretName: custom-certs

Other components

CLI

Use kfpfor interact with Kubeflow as and API for Python, the CLI version only works with GCP (Google Cloud Platform).

  • You can perform all operations with the API