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: articles/azure-compute-fleet/quickstart-create-azure-cli.md
+45-46Lines changed: 45 additions & 46 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ ms.topic: how-to
7
7
ms.service: azure-compute-fleet
8
8
ms.date: 05/09/2025
9
9
ms.reviewer: jushiman
10
-
ms.custom: devx-track-arm-template, build-2024
10
+
ms.custom: devx-track-azurecli
11
11
---
12
12
13
13
# Create an Azure Compute Fleet using Azure CLI
@@ -24,68 +24,67 @@ This article steps through using an ARM template to create an Azure Compute Flee
24
24
- Before using Compute Fleet, complete the feature registration and configure role-based access controls (RBAC).
25
25
26
26
27
-
## Feature registration
27
+
###Feature registration
28
28
29
29
Register the Azure Compute Fleet resource provider with your subscription using Azure CLI. Registration can take up to 30 minutes to successfully show as registered.
30
30
31
31
```bash
32
32
az provider register --namespace 'Microsoft.AzureFleet'
33
33
```
34
+
### Set Environment variables
34
35
35
-
### [Azure portal](#tab/portal-1)
36
-
37
-
1. In the [Azure portal](https://portal.azure.com), navigate to your subscriptions.
38
-
1. Select the subscription you want to enable Azure Compute Fleet on.
39
-
1. Under **Settings**, select **Resource providers**.
40
-
1. Search for *Microsoft.AzureFleet* and register the provider.
41
-
42
-
---
43
-
44
-
45
-
## Role-based access control permissions
46
-
47
-
Assign the appropriate RBAC permissions to use Azure Compute Fleet.
48
-
49
-
1. In the [Azure portal](https://portal.azure.com), navigate to your subscriptions.
50
-
1. Select the subscription you want to adjust RBAC permissions.
51
-
1. Select **Access Control (IAM)**.
52
-
1. Select *Add*, then **Add Role Assignment**.
53
-
1. Search for **Virtual Machine Contributor** and highlight it. Select **Next**.
54
-
1. Click on **+ Select Members**.
55
-
1. Search for *Azure Fleet Resource Provider* role.
56
-
1. Select the *Azure Fleet Resource Provider* and select **Review + Assign**.
57
-
1. Repeat the previous steps for the *Network Contributor* role and the *Managed Identity Operator* role.
58
-
59
-
If you're using images stored in Compute Gallery when deploying your Compute Fleet, also repeat the previous steps for the *Compute Gallery Sharing Admin* role.
60
-
61
-
For more information on assigning roles, see [assign Azure roles using the Azure portal](../role-based-access-control/quickstart-assign-role-user-portal.md).
ARM templates let you deploy groups of related resources. In a single template, you can create the Virtual Machine Scale Set, install applications, and configure autoscale rules. With the use of variables and parameters, this template can be reused to update existing, or create extra scale sets. You can deploy templates through the Azure portal, Azure CLI, or Azure PowerShell, or from continuous integration / continuous delivery (CI/CD) pipelines.
51
+
```bash
52
+
az group create --name $MY_RESOURCE_GROUP_NAME --location $REGION
Setup a password that meets the [password requirements for Azure VMs](https://learn.microsoft.com/en-us/azure/virtual-machines/windows/faq#what-are-the-password-requirements-when-creating-a-vm-).
79
74
75
+
export ADMIN_PASSWORD="<azurecompliantpassword>"
80
76
81
-
## Clean up resources
82
77
83
-
When no longer needed, you can use [az group delete](/cli/azure/group) to remove the resource group, scale set, and all related resources as follows. The `--no-wait` parameter returns control to the prompt without waiting for the operation to complete. The `--yes` parameter confirms that you wish to delete the resources without another prompt to do so.
78
+
### Create Compute Fleet
84
79
85
-
```azurecli-interactive
86
-
az group delete --name myResourceGroup --yes --no-wait
0 commit comments