You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: scenarios/AksKaito/README.md
+70-66Lines changed: 70 additions & 66 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,17 @@ ms.author: schaffererin
9
9
10
10
---
11
11
12
-
# Deploy an AI model on Azure Kubernetes Service (AKS) with the AI toolchain operator (preview)
12
+
## Quickstart: Create a Linux virtual machine with the Azure CLI on Azure
13
+
14
+
**Applies to:**:heavy_check_mark: Linux VMs
15
+
16
+
[](https://go.microsoft.com/fwlink/?linkid=2262692)
17
+
18
+
This quickstart shows you how to use the Azure CLI to deploy a Linux virtual machine (VM) in Azure. The Azure CLI is used to create and manage Azure resources via either the command line or scripts.
19
+
20
+
If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/?WT.mc_id=A261C142F) before you begin.
21
+
22
+
## Deploy an AI model on Azure Kubernetes Service (AKS) with the AI toolchain operator (preview)
13
23
14
24
The AI toolchain operator (KAITO) is a managed add-on for AKS that simplifies the experience of running OSS AI models on your AKS clusters. The AI toolchain operator automatically provisions the necessary GPU nodes and sets up the associated inference server as an endpoint server to your AI models. Using this add-on reduces your onboarding time and enables you to focus on AI model usage and development rather than infrastructure setup.
15
25
@@ -36,97 +46,91 @@ This article shows you how to enable the AI toolchain operator add-on and deploy
36
46
*[Install the Azure CLI AKS preview extension](#install-the-azure-cli-preview-extension).
37
47
*[Register the AI toolchain operator add-on feature flag](#register-the-ai-toolchain-operator-add-on-feature-flag).
38
48
39
-
### Install the Azure CLI preview extension
49
+
##Set up resource group
40
50
41
-
1. Install the Azure CLI preview extension using the [az extension add][az-extension-add] command.
2. Update the extension to make sure you have the latest version using the [az extension update][az-extension-update] command.
59
+
az group create \
60
+
--name $RG_NAME \
61
+
--location $REGION \
62
+
```
48
63
49
-
```azurecli-interactive
50
-
az extension update --name aks-preview
51
-
```
64
+
## Install the Azure CLI preview extension
52
65
53
-
### Register the AI toolchain operator add-on feature flag
66
+
Install the Azure CLI preview extension using the [az extension add][az-extension-add] command. Then update the extension to make sure you have the latest version using the [az extension update][az-extension-update] command.
54
67
55
-
1. Register the AIToolchainOperatorPreview feature flag using the [az feature register][az-feature-register] command.
68
+
```bash
69
+
az extension add --name aks-preview
70
+
az extension update --name aks-preview
71
+
```
56
72
57
-
```azurecli-interactive
58
-
az feature register --namespace "Microsoft.ContainerService" --name "AIToolchainOperatorPreview"
59
-
```
73
+
## Register the AI toolchain operator add-on feature flag
60
74
61
-
It takes a few minutes for the registration to complete.
75
+
Register the AIToolchainOperatorPreview feature flag using the az feature register command.
76
+
It takes a few minutes for the registration to complete.
62
77
63
-
2. Verify the registration using the [az feature show][az-feature-show] command.
78
+
```bash
79
+
az feature register --namespace "Microsoft.ContainerService" --name "AIToolchainOperatorPreview"
80
+
```
64
81
65
-
```azurecli-interactive
66
-
az feature show --namespace "Microsoft.ContainerService" --name "AIToolchainOperatorPreview"
67
-
```
82
+
Verify the registration using the [az feature show][az-feature-show] command.
68
83
69
-
### Export environment variables
84
+
```bash
85
+
az feature show --namespace "Microsoft.ContainerService" --name "AIToolchainOperatorPreview"
86
+
```
70
87
71
-
* To simplify the configuration steps in this article, you can define environment variables using the following commands. Make sure to replace the placeholder values with your own.
88
+
## Create an AKS cluster with the AI toolchain operator add-on enabled
72
89
73
-
```azurecli-interactive
74
-
export AZURE_SUBSCRIPTION_ID="mySubscriptionID"
75
-
export AZURE_RESOURCE_GROUP="myResourceGroup"
76
-
export AZURE_LOCATION="myLocation"
77
-
export CLUSTER_NAME="myClusterName"
78
-
```
90
+
Create an Azure resource group using the [az group create][az-group-create] command.
79
91
80
-
## Enable the AI toolchain operator add-on on an AKS cluster
92
+
```bash
93
+
az group create --name ${AZURE_RESOURCE_GROUP} --location ${REGION}
94
+
```
81
95
82
-
The following sections describe how to create an AKS cluster with the AI toolchain operator add-on enabled and deploy a default hosted AI model.
96
+
Create an AKS cluster with the AI toolchain operator add-on enabled using the [az aks create][az-aks-create] command with the `--enable-ai-toolchain-operator` and `--enable-oidc-issuer` flags.
83
97
84
-
### Create an AKS cluster with the AI toolchain operator add-on enabled
98
+
> [!NOTE]
99
+
> AKS creates a managed identity once you enable the AI toolchain operator add-on. The managed identity is used to create GPU node pools in the managed AKS cluster. Proper permissions need to be set for it manually following the steps introduced in the following sections.
100
+
>
101
+
> AI toolchain operator enablement requires the enablement of OIDC issuer.
85
102
86
-
1. Create an Azure resource group using the [az group create][az-group-create] command.
103
+
```bash
104
+
az aks create --location ${REGION} \
105
+
--resource-group ${AZURE_RESOURCE_GROUP} \
106
+
--name ${CLUSTER_NAME} \
107
+
--enable-oidc-issuer \
108
+
--enable-ai-toolchain-operator \
109
+
--generate-ssh-keys
110
+
```
87
111
88
-
```azurecli-interactive
89
-
az group create --name ${AZURE_RESOURCE_GROUP} --location ${AZURE_LOCATION}
90
-
```
91
-
92
-
2. Create an AKS cluster with the AI toolchain operator add-on enabled using the [az aks create][az-aks-create] command with the `--enable-ai-toolchain-operator` and `--enable-oidc-issuer` flags.
112
+
On an existing AKS cluster, you can enable the AI toolchain operator add-on using the [az aks update][az-aks-update] command.
93
113
94
-
```azurecli-interactive
95
-
az aks create --location ${AZURE_LOCATION} \
114
+
```bash
115
+
az aks update --name${CLUSTER_NAME} \
96
116
--resource-group ${AZURE_RESOURCE_GROUP} \
97
-
--name ${CLUSTER_NAME} \
98
117
--enable-oidc-issuer \
99
-
--enable-ai-toolchain-operator \
100
-
--generate-ssh-keys
101
-
```
102
-
103
-
> [!NOTE]
104
-
> AKS creates a managed identity once you enable the AI toolchain operator add-on. The managed identity is used to create GPU node pools in the managed AKS cluster. Proper permissions need to be set for it manually following the steps introduced in the following sections.
105
-
>
106
-
> AI toolchain operator enablement requires the enablement of OIDC issuer.
107
-
108
-
3. On an existing AKS cluster, you can enable the AI toolchain operator add-on using the [az aks update][az-aks-update] command.
109
-
110
-
```azurecli-interactive
111
-
az aks update --name ${CLUSTER_NAME} \
112
-
--resource-group ${AZURE_RESOURCE_GROUP} \
113
-
--enable-oidc-issuer \
114
-
--enable-ai-toolchain-operator
115
-
```
118
+
--enable-ai-toolchain-operator
119
+
```
116
120
117
121
## Connect to your cluster
118
122
119
-
1. Configure `kubectl` to connect to your cluster using the [az aks get-credentials][az-aks-get-credentials] command.
123
+
Configure `kubectl` to connect to your cluster using the [az aks get-credentials][az-aks-get-credentials] command.
120
124
121
-
```azurecli-interactive
122
-
az aks get-credentials --resource-group ${AZURE_RESOURCE_GROUP} --name ${CLUSTER_NAME}
123
-
```
125
+
```bash
126
+
az aks get-credentials --resource-group ${AZURE_RESOURCE_GROUP} --name ${CLUSTER_NAME}
127
+
```
124
128
125
-
2. Verify the connection to your cluster using the `kubectl get` command.
129
+
Verify the connection to your cluster using the `kubectl get` command.
126
130
127
-
```azurecli-interactive
128
-
kubectl get nodes
129
-
```
131
+
```bash
132
+
kubectl get nodes
133
+
```
130
134
131
135
## Export environment variables
132
136
@@ -248,4 +252,4 @@ For more inference model options, see the [KAITO GitHub repository](https://gith
0 commit comments