Skip to content

Commit 6f29cb0

Browse files
authored
Update aks-create-clusters-api.md
Edits
1 parent 7073bc1 commit 6f29cb0

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

AKS-Arc/aks-create-clusters-api.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,21 @@ ms.reviewer: rjaini
1313

1414
[!INCLUDE [hci-applies-to-23h2](includes/hci-applies-to-23h2.md)]
1515

16-
This article describes how to create a Kubernetes clusters on Azure Local using the REST API. The Azure Resource type for [AKS Arc provisioned clusters](/azure/templates/microsoft.hybridcontainerservice/provisionedclusterinstances?pivots=deployment-language-arm-template) is **"Microsoft.HybridContainerService/provisionedClusterInstances"**. This is an extension of the [Connected cluster](/azure/templates/microsoft.kubernetes/connectedclusters?pivots=deployment-language-arm-template) resource type **"Microsoft.Kubernetes/connectedClusters"**. Due to this dependency, you would need to first create a Connected cluster resource before creating an AKS Arc resource.
16+
This article describes how to create a Kubernetes clusters on Azure Local using the REST API. The Azure resource type for [AKS Arc provisioned clusters](/azure/templates/microsoft.hybridcontainerservice/provisionedclusterinstances?pivots=deployment-language-arm-template) is **"Microsoft.HybridContainerService/provisionedClusterInstances"**. This is an extension of the [Connected Cluster](/azure/templates/microsoft.kubernetes/connectedclusters?pivots=deployment-language-arm-template) resource type, **"Microsoft.Kubernetes/connectedClusters"**. Due to this dependency, you must first create a Connected Cluster resource before creating an AKS Arc resource.
1717

1818
## Before you begin
1919

2020
Before you begin, make sure you have the following details from your on-premises infrastructure administrator:
2121

22-
- **Azure subscription ID** - The Azure subscription ID where Azure Local is used for deployment and registration.
23-
- **Custom Location ID** - Azure Resource Manager ID of the custom location. The custom location is configured during the Azure Local cluster deployment. Your infrastructure admin should give you the Resource Manager ID of the custom location. This parameter is required in order to create Kubernetes clusters. You can also get the Resource Manager ID using `az customlocation show --name "<custom location name>" --resource-group <azure resource group> --query "id" -o tsv`, if the infrastructure admin provides a custom location name and resource group name.
24-
- **Network ID** - Azure Resource Manager ID of the Azure Local logical network created following [these steps](aks-networks.md). Your admin should give you the ID of the logical network. This parameter is required in order to create Kubernetes clusters. You can also get the Azure Resource Manager ID using `az stack-hci-vm network lnet show --name "<lnet name>" --resource-group <azure resource group> --query "id" -o tsv` if you know the resource group in which the logical network was created.
25-
- **Create an SSH key pair** - Create an SSH key pair in Azure and store the private key file for troubleshooting and log collection purposes. For detailed instructions, see [Create and store SSH keys with the Azure CLI](/azure/virtual-machines/ssh-keys-azure-cli), or in the [Azure portal](/azure/virtual-machines/ssh-keys-portal).
26-
- To connect to the Kubernetes cluster from anywhere, create a Microsoft Entra group and add members to it. All the members in the Microsoft Entra group have cluster administrator access to the cluster. Make sure to add yourself as a member to the Microsoft Entra group. If you don't add yourself, you cannot access the Kubernetes cluster using kubectl. For more information about creating Microsoft Entra groups and adding users, see [Manage Microsoft Entra groups and group membership](/entra/fundamentals/how-to-manage-groups).
22+
- **Azure subscription ID**: The Azure subscription ID that Azure Local uses for deployment and registration.
23+
- **Custom Location ID**: The Azure Resource Manager ID of the custom location. The custom location is configured during the Azure Local cluster deployment. Your infrastructure admin should give you the Resource Manager ID of the custom location. This parameter is required in order to create Kubernetes clusters. If the infrastructure admin provides a custom location name and resource group name, you can also get the Resource Manager ID using the `az customlocation show --name "<custom location name>" --resource-group <azure resource group> --query "id" -o tsv` command.
24+
- **Network ID**: The Azure Resource Manager ID of the Azure Local logical network you created [following these steps](aks-networks.md). Your admin should give you the ID of the logical network. This parameter is required in order to create Kubernetes clusters. If you know the resource group in which the logical network was created, you can also get the Azure Resource Manager ID using the `az stack-hci-vm network lnet show --name "<lnet name>" --resource-group <azure resource group> --query "id" -o tsv` command.
25+
- **Create an SSH key pair**: Create an SSH key pair in Azure and store the private key file for troubleshooting and log collection purposes. For detailed instructions, see [Create and store SSH keys with the Azure CLI](/azure/virtual-machines/ssh-keys-azure-cli), or with the [Azure portal](/azure/virtual-machines/ssh-keys-portal).
26+
- To connect to the Kubernetes cluster from anywhere, create a Microsoft Entra group and add members to it. All the members in the Microsoft Entra group have cluster administrator access to the cluster. Make sure to add yourself as a member to the Microsoft Entra group. If you don't add yourself, you cannot access the Kubernetes cluster using **kubectl**. For more information about creating Microsoft Entra groups and adding users, see [Manage Microsoft Entra groups and group membership](/entra/fundamentals/how-to-manage-groups).
2727

28-
## Step 1: Create a Connected cluster resource
28+
## Step 1: Create a connected cluster resource
2929

30-
Refer to the API definition for [Connected clusters](/rest/api/hybridkubernetes/connected-cluster/create) and create PUT request with the **`kind`** property set as 'ProvisionedCluster'. Here is a sample PUT request to create a Connected cluster resource using the REST API:
30+
Refer to the API definition for [connected clusters](/rest/api/hybridkubernetes/connected-cluster/create) and create a **PUT** request with the `kind` property set to 'ProvisionedCluster'. The following example is a sample **PUT** request to create a connected cluster resource using the REST API:
3131

3232
```http
3333
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Kubernetes/connectedClusters/{connectedClusterName}?api-version=2024-01-01
@@ -56,11 +56,11 @@ Authorization: Bearer <access_token>
5656
}
5757
```
5858

59-
Replace all placeholder values with your actual details. For more information, see the [Connected cluster API documentation](/rest/api/hybridkubernetes/connected-cluster/create).
59+
Replace all placeholder values with your actual details. For more information, see the [connected cluster API documentation](/rest/api/hybridkubernetes/connected-cluster/create).
6060

61-
## Step 2: Create a Provisioned cluster resource
61+
## Step 2: Create a provisioned cluster resource
6262

63-
Refer to the API definition for [Provisioned clusters](/rest/api/hybridcontainer/provisioned-cluster-instances/create-or-update). In this PUT call, pass the Azure Resource Manager identifier created in the previous step as the URI parameter. Here is a sample HTTP PUT request to create a Provisioned cluster resource with only the required parameters:
63+
See the API definition for [provisioned clusters](/rest/api/hybridcontainer/provisioned-cluster-instances/create-or-update). In this **PUT** call, pass the Azure Resource Manager identifier created in the previous step as the URI parameter. The following code is an example HTTP **PUT** request to create a provisioned cluster resource with only the required parameters:
6464

6565
```http
6666
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HybridContainerService/provisionedClusterInstances/{clusterName}?api-version=2024-01-01-preview
@@ -106,15 +106,15 @@ Authorization: Bearer <access_token>
106106
107107
```
108108

109-
Replace the placeholder values with your actual details. For more information, see the [Provisioned cluster API documentation](/rest/api/hybridcontainer/provisioned-cluster-instances/create-or-update).
109+
Replace the placeholder values with your actual details. For more information, see the [provisioned cluster API documentation](/rest/api/hybridcontainer/provisioned-cluster-instances/create-or-update).
110110

111111
## Connect to the Kubernetes cluster
112112

113113
Now you can connect to your Kubernetes cluster by running the `az connectedk8s proxy` command from your development machine. Make sure you sign in to Azure before running this command. If you have multiple Azure subscriptions, select the appropriate subscription ID using the [az account set](/cli/azure/account#az-account-set) command.
114114

115-
This command downloads the kubeconfig of your Kubernetes cluster to your development machine and opens a proxy connection channel to your on-premises Kubernetes cluster. The channel is open for as long as the command runs. Let this command run for as long as you want to access your cluster. If it times out, close the CLI window, open a fresh one, then run the command again.
115+
This command downloads the **kubeconfig** of your Kubernetes cluster to your development machine and opens a proxy connection channel to your on-premises Kubernetes cluster. The channel is open for as long as the command runs. Let this command run for as long as you want to access your cluster. If it times out, close the CLI window, open a fresh one, and then run the command again.
116116

117-
You must have Contributor permissions on the resource group that hosts the Kubernetes cluster in order to run the following command successfully:
117+
You must have Contributor permissions on the resource group that hosts the Kubernetes cluster in order to successfully run the following command:
118118

119119
```azurecli
120120
az connectedk8s proxy --name $aksclustername --resource-group $resource_group --file .\aks-arc-kube-config
@@ -130,13 +130,13 @@ kubeconfig at .\\aks-arc-kube-config
130130
Press Ctrl+C to close proxy.
131131
```
132132

133-
Keep this session running and connect to your Kubernetes cluster from a different terminal/command prompt. Verify that you can connect to your Kubernetes cluster by running the kubectl get command. This command returns a list of the cluster nodes:
133+
Keep this session running and connect to your Kubernetes cluster from a different terminal or command prompt. Verify that you can connect to your Kubernetes cluster by running the `kubectl get` command. This command returns a list of the cluster nodes:
134134

135135
```azurecli
136136
kubectl get node -A --kubeconfig .\aks-arc-kube-config
137137
```
138138

139-
The following output example shows the node created in the previous steps. Make sure the node status is **Ready**:
139+
The following example output shows the node you created in the previous steps. Make sure the node status is **Ready**:
140140

141141
```output
142142
NAME STATUS ROLES AGE VERSION

0 commit comments

Comments
 (0)