Integrate Rok with Kubeflow Dashboard¶
This section will guide you through integrating Rok with the Kubeflow dashboard, so that you can visit Rok from the Snapshots tab in the Kubeflow UI.
Fast Forward
If you have already integrated Rok with your Kubeflow dashboard, expand this box to fast-forward.
Go to your GitOps repository, inside your
rok-tools
management environment:root@rok-tools:~# cd ~/ops/deploymentsSave your state:
root@rok-tools:~/ops/deployments# rok-j2 deploy/env.kubeflow-rok.j2 \ > -o deploy/env.kubeflow-rokCommit your changes:
root@rok-tools:~/ops/deployments# git commit -am "Integrate Rok with Kubeflow Dashboard"Proceed to the Verify section.
Choose one of the following options to integrate Rok with the Kubeflow dashboard:
- Option 1: Integrate Rok with Kubeflow Dashboard Automatically (preferred).
- Option 2: Integrate Rok with Kubeflow Dashboard Manually.
Overview
What You’ll Need¶
- A configured management environment.
- Your clone of the Arrikto GitOps repository.
- An existing Kubeflow deployment.
Option 1: Integrate Rok with Kubeflow Dashboard Automatically (preferred)¶
Integrate Rok with the Kubeflow dashboard by following the on-screen
instructions on the rok-deploy
user interface.
If rok-deploy
is not already running, start it with:
Proceed to the Summary section.
Option 2: Integrate Rok with Kubeflow Dashboard Manually¶
If you want to integrate Rok with the Kubeflow dashboard, follow the instructions below.
Procedure¶
Go to your GitOps repository, inside your
rok-tools
management environment:root@rok-tools:~# cd ~/ops/deploymentsConfigure
rok-cluster
kustomization. Choose based on your platform.Edit the
rok/rok-cluster/overlays/deploy/kustomization.yaml
and enable thekf-configvars.yaml
patch by uncommenting the corresponding line. The final result will look like this:patches: - path: patches/storage.yaml - path: patches/retention.yaml - path: patches/configvars.yaml - path: patches/image-pull-secrets.yaml - path: patches/kf-configvars.yamlEdit the
rok/rok-cluster/overlays/deploy/kustomization.yaml
and enable thekf-configvars.yaml
patch by uncommenting the corresponding line. The final result will look like this:patches: - path: patches/storage.yaml - path: patches/retention.yaml - path: patches/configvars.yaml - path: patches/image-pull-secrets.yaml - path: patches/kf-configvars.yamlEdit the
rok/rok-cluster/overlays/deploy/kustomization.yaml
and enable thekf-configvars.yaml
patch by uncommenting the corresponding line. The final result will look like this:patches: - path: patches/storage.yaml - path: patches/retention.yaml - path: patches/configvars.yaml - path: patches/image-pull-secrets.yaml - path: patches/kf-configvars.yamlLet Rok use Kubeflow:
root@rok-tools:~/ops/deployments# export ROK_CLUSTER_USE_KUBEFLOW=trueConfigure the
deploy
overlay to use the corresponding component:root@rok-tools:~/ops/deployments# rok-j2 \ > rok/rok-cluster/overlays/deploy/kustomization.yaml.j2 \ > -o rok/rok-cluster/overlays/deploy/kustomization.yamlAir Gapped
Patch the kustomization to use the mirrored images:
root@rok-tools:~/ops/deployments# rok-image-patch \ > --kustomizations rok/rok-cluster/overlays/deployFollow the on-screen instructions and provide any necessary input.
Save your state:
root@rok-tools:~/ops/deployments# rok-j2 deploy/env.kubeflow-rok.j2 \ > -o deploy/env.kubeflow-rokCommit your changes:
root@rok-tools:~/ops/deployments# git commit -am "Integrate Rok with Kubeflow Dashboard"Reapply the Rok cluster overlay:
root@rok-tools:~/ops/deployments# rok-deploy --apply rok/rok-cluster/overlays/deployMark your progress:
root@rok-tools:~/ops/deployments# export DATE=$(date -u "+%Y-%m-%dT%H.%M.%SZ")root@rok-tools:~/ops/deployments# git tag \ > -a deploy/${DATE?}/develop/kubeflow-rok \ > -m "Integrate Rok with Kubeflow Dashboard"
Verify¶
Go to your GitOps repository, inside your
rok-tools
management environment:root@rok-tools:~# cd ~/ops/deploymentsRestore the required context from previous sections:
root@rok-tools:~/ops/deployments# source deploy/env.cloudidentityroot@rok-tools:~/ops/deployments# export ROK_CLUSTER_NAMESPACEVerify you have enabled the Kubeflow dashboard:
root@rok-tools:~/ops/deployments# kubectl get rokcluster \ > -n ${ROK_CLUSTER_NAMESPACE?} \ > -o yaml \ > | grep -q 'gw.ui.kubeflow_dashboard_enabled: true' \ > && echo OK || echo FAIL OK