Skip to content

Commit

Permalink
docs: fix terraform and update readme (#637)
Browse files Browse the repository at this point in the history
**Reason for Change**:
Fixes a bug found in Terraform configuration which was not properly
storing ACR token as a K8s dockerconfigjson secret. Also updating the
README to point users to examples and docs after provisioning resources
and installing KAITO.
  • Loading branch information
pauldotyu authored Oct 17, 2024
1 parent 314a80e commit 58894ba
Show file tree
Hide file tree
Showing 3 changed files with 98 additions and 7 deletions.
82 changes: 82 additions & 0 deletions terraform/.terraform.lock.hcl

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 14 additions & 6 deletions terraform/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,19 +39,23 @@ Initialize the Terraform providers.
terraform init
```

> [!NOTE]
> The following variables in the [variables.tf](./variables.tf) file are available for customization:
>
> - `location` - The Azure region to deploy the resources. Be sure you have the necessary quota in the region.
> - `kaito_gpu_provisioner_version` - The version of the KAITO GPU Provisioner.
> - `kaito_workspace_version` - The version of the KAITO Workspace.
## Deploy

Before you deploy, review the following variables in the [variables.tf](./variables.tf) file which are available for customization:

- `location` - The Azure region to deploy the resources. Be sure you have the necessary quota in the region.
- `kaito_gpu_provisioner_version` - The version of the KAITO GPU Provisioner.
- `kaito_workspace_version` - The version of the KAITO Workspace.
- `registry_repository_name` - The name of the output image when running a sample fine-tuning job.

Run the Terraform apply command and enter `yes` when prompted to deploy the Azure resources.

```bash
terraform apply
```

## Verify

Log into the AKS cluster.

```bash
Expand All @@ -72,6 +76,10 @@ kubectl get po -n gpu-provisioner
kubectl get po -n kaito-workspace
```

## Use

KAITO is now installed on the AKS cluster but no workspaces have been created. To use the KAITO workspaces, please refer to the YAML manifests found in the [examples](../examples/) directory or KAITO [docs](../docs/).

## Cleanup

Run the Terraform destroy command and enter `yes` when prompted to delete the Azure resources.
Expand Down
3 changes: 2 additions & 1 deletion terraform/kaito.tf
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ resource "kubernetes_secret" "example" {
auths = {
"${azurerm_container_registry.example.login_server}" = {
"username" = azurerm_container_registry_token.example.name
"password" = azurerm_container_registry_token_password.example.password1
"password" = azurerm_container_registry_token_password.example.password1[0].value
"auth" = base64encode("${azurerm_container_registry_token.example.name}:${azurerm_container_registry_token_password.example.password1[0].value}")
}
}
})
Expand Down

0 comments on commit 58894ba

Please sign in to comment.