A Microsoft desktop and app virtualization service that runs on Azure. Previously known as Windows Virtual Desktop.
Root Cause Analysis
The error DeploymentFailed / InvalidTemplate occurs because the ARM template or Bicep module initiating the extension deployment evaluates the type field using a template function/expression (e.g., [parameters('extensionType')] or [concat(...)]). ARM template engine rules strictly forbid expressions in the resource type field.
Because template validation fails at the Azure Resource Manager (ARM) plane, the deployment aborts before generating a API payload to the guest, explaining why no local execution logs exist under C:\ProgramData\GuestConfig\extension_logs\.
Resolution Steps
Hardcode the Resource Type in the Template Ensure the type property in your deployment template is hardcoded as a literal string rather than an expression.
For Azure Arc-enabled Servers (Hybrid/On-Premises):
JSON
"type"
__For Standard Azure VMs:__
JSON
```yaml
"type"
```
__Fix Resource Naming & Parent Structure__ Separate the parent machine name from the extension name instead of dynamically concatenating them inside `type`:
JSON
```json
{
```
- Deploy via Direct Az CLI / PowerShell Workaround If deploying through the Azure Portal UI or a pre-packaged template triggers this, bypass ARM template processing by issuing a direct Arc extension CLI command: Code snippet
az connectedmachine extension create \
--resource-group "Robocamp"
--machine-name "Firestorm2"
--name "AzureVirtualDesktop"
--publisher "Microsoft.AzureVirtualDesktop"
--type "CloudDeviceExtension"
--location "<your-region>"