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
You can use the Bicep template to create a new Hybrid Worker group, create a new Azure Windows VM and add it to an existing Hybrid Worker Group. Learn more about [Bicep](../azure-resource-manager/bicep/overview.md)
298
+
You can use the Bicep template to create a new Hybrid Worker group, create a new Azure Windows VM and add it to an existing Hybrid Worker Group. Learn more about [Bicep](../azure-resource-manager/bicep/overview.md).
299
+
300
+
Follow the steps mentioned below as an example:
301
+
302
+
1. Create a Hybrid Worker Group.
303
+
1. Create either an Azure VM or Arc-enabled server. Alternatively, you can also use an existing Azure VM or Arc-enabled server.
304
+
1. Connect the Azure VM or Arc-enabled Server to the above created Hybrid Worker Group.
305
+
1. Generate a new GUID and pass it as the name of the Hybrid Worker.
306
+
1. Enable System-assigned managed identity on the VM.
307
+
1. Install Hybrid Worker Extension on the VM.
308
+
1. To confirm if the extension has been successfully installed on the VM, In **Azure portal**, go to the VM > **Extensions** tab and check the status of Hybrid Worker extension installed on the VM.
You can use an Azure Resource Manager (ARM) template to create a new Azure Windows VM and connect it to an existing Automation account and Hybrid Worker Group. To learn more about ARM templates, see [What are ARM templates?](../azure-resource-manager/templates/overview.md)
526
536
537
+
Follow the steps mentioned below as an example:
538
+
539
+
1. Create a Hybrid Worker Group.
540
+
1. Create either an Azure VM or Arc-enabled server. Alternatively, you can also use an existing Azure VM or Arc-enabled server.
541
+
1. Connect the Azure VM or Arc-enabled Server to the above created Hybrid Worker Group.
542
+
1. Generate a new GUID and pass it as the name of the Hybrid Worker.
543
+
1. Enable System-assigned managed identity on the VM.
544
+
1. Install Hybrid Worker Extension on the VM.
545
+
1. To confirm if the extension has been successfully installed on the VM, In **Azure portal**, go to the VM > **Extensions** tab and check the status of Hybrid Worker extension installed on the VM.
546
+
547
+
527
548
**Review the template**
528
549
529
550
```json
@@ -953,6 +974,28 @@ To install and use Hybrid Worker extension using REST API, follow these steps. T
953
974
954
975
#### [Azure CLI](#tab/cli)
955
976
977
+
You can use Azure CLI to create a new Hybrid Worker group, create a new Azure VM, add it to an existing Hybrid Worker Group and install the Hybrid Worker extension. Learn more about [Azure CLI](https://learn.microsoft.com/cli/azure/what-is-azure-cli)
978
+
979
+
Follow the steps mentioned below as an example:
980
+
981
+
1. Create a Hybrid Worker Group
982
+
```azurecli-interactive
983
+
az automation hrwg create --automation-account-name accountName --resource-group groupName --name hybridrunbookworkergroupName
984
+
```
985
+
1. Create an Azure VM or Arc-enabled server and add it to the above created Hybrid Worker Group. Use the below command to add an existing Azure VM or Arc-enabled Server to the Hybrid Worker Group. Generate a new GUID and pass it as `hybridRunbookWorkerGroupName. vmResourceId`. To fetch it, go to the **Properties** tab of the VM on Azure portal.
1. Follow the steps [here](../active-directory/managed-identities-azure-resources/qs-configure-portal-windows-vm.md#enable-system-assigned-managed-identity-on-an-existing-vm) to enable the System-assigned managed identity on the VM.
991
+
1. Install Hybrid Worker Extension on the VM
992
+
993
+
```azurecli-interactive
994
+
az vm extension set --name HybridWorkerExtension --publisher Microsoft.Azure.Automation.HybridWorker --version 1.1 --vm-name <vmname> -g <resourceGroupName> \
1. To confirm if the extension has been successfully installed on the VM, In **Azure portal**, go to the VM > **Extensions** tab and check the status of Hybrid Worker extension installed on the VM.
998
+
956
999
**Manage Hybrid Worker Extension**
957
1000
958
1001
- To create, delete, and manage extension-based Hybrid Runbook Worker groups, see [az automation hrwg | Microsoft Docs](/cli/azure/automation/hrwg)
@@ -963,6 +1006,30 @@ After creating new Hybrid Runbook Worker, you must install the extension on the
963
1006
964
1007
#### [PowerShell](#tab/ps)
965
1008
1009
+
You can use PowerShell cmdlets to create a new Hybrid Worker group, create a new Azure VM, add it to an existing Hybrid Worker Group and install the Hybrid Worker extension.
1. Create an Azure VM or Arc-enabled server and add it to the above created Hybrid Worker Group. Use the below command to add an existing Azure VM or Arc-enabled Server to the Hybrid Worker Group. Generate a new GUID and pass it as `RunbookWorkerName. VmResourceId`. To fetch it, go to the **Properties** tab of the VM on Azure portal.
1. Follow the steps [here](../active-directory/managed-identities-azure-resources/qs-configure-portal-windows-vm.md#enable-system-assigned-managed-identity-on-an-existing-vm) to enable the System-assigned managed identity on the VM.
1024
+
1. Install Hybrid Worker Extension on the VM.
1025
+
1026
+
:::image type="content" source="./media/extension-based-hybrid-runbook-worker-install/hybrid-worker-extension-settings-powershell-inline.png" alt-text="Screenshot of Hybrid Worker Extension settings in PowerShell." lightbox="./media/extension-based-hybrid-runbook-worker-install/hybrid-worker-extension-settings-powershell-expanded.png":::
1027
+
1028
+
1. To confirm if the extension has been successfully installed on the VM, In **Azure portal**, go to the VM > **Extensions** tab and check the status of Hybrid Worker extension installed on the VM.
1029
+
1030
+
1031
+
**Manage Hybrid Worker Extension**
1032
+
966
1033
You can use the following PowerShell cmdlets to manage Hybrid Runbook Worker and Hybrid Runbook Worker groups:
0 commit comments