> ## Documentation Index
> Fetch the complete documentation index at: https://docs.coreweave.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Run Kubeflow

> Set up and deploy Kubeflow on CKS for machine learning workflows with certificate management

[Kubeflow](https://www.kubeflow.org/) is an open-source machine learning platform that runs on Kubernetes, providing tools for the complete ML lifecycle from development to deployment.

This guide shows you how to set up Kubeflow on CKS by covering the following:

* Configuring your cluster for Kubeflow compatibility
* Installing certificate management components
* Deploying Kubeflow using the default OSS manifests
* Accessing the Kubeflow dashboard

## Prerequisites

Before installing Kubeflow, ensure you have the following:

* A Kubernetes cluster on CoreWeave accessible with `kubectl`
* `kustomize` installed and configured to work with your cluster

## Setup

1. Clone the Kubeflow manifests repository and navigate to it by running the following commands:

   ```bash theme={"system"}
   $ git clone --depth 1 --branch v1.10.1 https://github.com/kubeflow/manifests.git
   $ cd manifests
   ```

2. Edit the [Cilium Config](https://github.com/cilium/cilium) by running the following command:

   ```bash theme={"system"}
   $ kubectl edit -n cw-cilium-system cm cilium-config
   ```

   Add the following value and then save and exit:

   ```yaml theme={"system"}
   bpf-lb-sock-hostns-only: "true"
   ```

   For example, the `cilium-config` file section should look similar to this:

   ```yaml highlight={3} theme={"system"}
   bpf-lb-mode: dsr
   bpf-lb-sock: "false"
   bpf-lb-sock-hostns-only: "true"
   bpf-lb-sock-terminate-pod-connections: "false"
   bpf-map-dynamic-size-ratio: "0.0025"
   bpf-policy-map-max: "16384"
   ```

   Apply the changes by running the following command:

   ```bash theme={"system"}
   $ kubectl rollout restart -n cw-cilium-system ds cilium
   ```

   Note: Disregard deprecation warnings.

3. Install cert-manager and the cert-issuer by running the following commands:

   ```bash theme={"system"}
   $ kustomize build common/cert-manager/base | kubectl apply -f -
   $ kustomize build common/cert-manager/kubeflow-issuer/base | kubectl apply -f -
   ```

4. Install Kubeflow using the OSS default manifests by running the following commands:

   ```bash theme={"system"}
   while ! kustomize build example | kubectl apply --server-side --force-conflicts -f -; do echo "Retrying to apply resources"; sleep 20; done
   ```

## Using Kubeflow

Once Kubeflow is installed, you can access the dashboard and other components. The default namespace for Kubeflow is `kubeflow`.

The easiest way to start using Kubeflow is to port-forward the main dashboard service by running the following command:

```bash theme={"system"}
kubectl port-forward svc/istio-ingressgateway -n istio-system 8080:80
```

To view the Kubeflow dashboard go to [http://localhost:8080](http://localhost:8080).

The default credentials are used for basic authentication. Access the dashboard using the following credentials:

User: `user@example.com`
Password: `12341234`
