The support for Run:ai in Knavigator is currently experimental. To utilize this feature, a valid subscription with Run:ai is required.
- Create a new project
Navigate to the Run:ai portal and create a new project. Upon creating the project, the portal will provide Helm instructions for deploying the Run:ai cluster. These instructions will include:
controlPlane.url
controlPlane.clientSecret
cluster.uid
- Define Environment Variables:
RUNAI_CONTROL_PLANE_URL
: Set this to thecontrolPlane.url
provided.RUNAI_CLIENT_SECRET
: Set this to thecontrolPlane.clientSecret
provided.RUNAI_CLUSTER_ID
: Set this to thecluster.uid
provided.
- Run the Deployment Script:
Execute the create-test-cluster.sh script to complete the deployment.
This script will deploy a kind
cluster if necessary, followed by deploying KWOK
and Prometheus
. It will then prompt you to select a workload manager. Choose the run:ai
option.
- Replace cluster UID and project name in the sample workflow files:
Update the sample workflow files test-trainingworkload.yml and test-distributedworkload.yml by replacing <RUNAI_CLUSTER_ID>
with the cluster UID and <RUNAI_PROJECT>
with the project name.
- Run the workflows
Run a Run:ai training workload:
./bin/knavigator -workflow resources/workflows/runai/test-trainingworkload.yml -cleanup
Run a Run:ai distributed workload:
./bin/knavigator -workflow resources/workflows/runai/test-distributedworkload.yml -cleanup