Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

az deployment group create error message was insufficient. #29202

Open
lovettchris opened this issue Jun 19, 2024 · 4 comments
Open

az deployment group create error message was insufficient. #29202

lovettchris opened this issue Jun 19, 2024 · 4 comments
Labels
Auto-Assign Auto assign by bot Auto-Resolve Auto resolve by bot Azure Deployments az deployment/bicep/stack/deployment-scripts/ts/group export bug This issue requires a change to an existing behavior in the product in order to be resolved. Service Attention This issue is responsible by Azure service team. Similar-Issue

Comments

@lovettchris
Copy link

Describe the bug

I had some square brackets missing in my ARM template and the deployment failed with an obscure error message.

The problem is the error does not include the "invalid computer name" value that I was trying to set. This bug was hard to find because my template contained:

"virtualMachineComputerName": "parameters('virtualMachineName')",

instead of

"virtualMachineComputerName": "[parameters('virtualMachineName')]",

If the error had shown the string "parameters('virtualMachineName')" as the invalid computer name I would have known instantly how to fix it. It would be awesome if the error message could be improved to include this information.

Related command

az deployment group create

Errors

{"status":"Failed","error":{"code":"DeploymentFailed","target":"/subscriptions/0533c3bf-0d48-47d3-8002-7d58f1ff38f0/resourceGroups/GCRIaaSLoanT4p2/providers/Microsoft.Resources/deployments/gamevm_deployment_windows11_template","message":"At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/arm-deployment-operations for usage details.","details":[{"code":"InvalidParameter","target":"computerName","message":"Windows computer name cannot be more than 15 characters long, be entirely numeric, or contain the following characters: ` ~ ! @ # $ % ^ & * ( ) = + _ [ ] { } \ | ; : . ' " , < > / ?."}]}}

Issue script & Debug output

same as Errors

Expected behavior

A better error.

Environment Summary

azure-cli 2.55.0 *

core 2.55.0 *
telemetry 1.1.0
Extensions:
account 0.2.5
azure-devops 0.26.0
bastion 0.2.5
ssh 2.0.2
storage-preview 1.0.0b1

Dependencies:
msal 1.24.0b2
azure-mgmt-resource 23.1.0b2

Python location 'C:\Program Files\Microsoft SDKs\Azure\CLI2\python.exe'
Extensions directory 'C:\Users\clovett.REDMOND.azure\cliextensions'

Python (Windows) 3.11.5 (tags/v3.11.5:cce6ba9, Aug 24 2023, 14:38:34) [MSC v.1936 64 bit (AMD64)]

Additional context

No response

@lovettchris lovettchris added the bug This issue requires a change to an existing behavior in the product in order to be resolved. label Jun 19, 2024
Copy link

Hi @lovettchris,

2.55.0 is not the latest Azure CLI(2.61.0).

If you haven't already attempted to do so, please upgrade to the latest Azure CLI version by following https://learn.microsoft.com/en-us/cli/azure/update-azure-cli.

@azure-client-tools-bot-prd azure-client-tools-bot-prd bot added the Auto-Resolve Auto resolve by bot label Jun 19, 2024
Copy link

Hi @lovettchris
Find similar issue #22434.

Issue title Deployments failing on App GW NSG rule validation after initial deployment
Create time 2022-05-13
Comment number 7

Please confirm if this resolves your issue.

@yonzhan
Copy link
Collaborator

yonzhan commented Jun 19, 2024

Thank you for opening this issue, we will look into it.

@microsoft-github-policy-service microsoft-github-policy-service bot added Azure Deployments az deployment/bicep/stack/deployment-scripts/ts/group export Service Attention This issue is responsible by Azure service team. labels Jun 19, 2024
Copy link
Contributor

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @Azure/deployments-owners.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Auto-Assign Auto assign by bot Auto-Resolve Auto resolve by bot Azure Deployments az deployment/bicep/stack/deployment-scripts/ts/group export bug This issue requires a change to an existing behavior in the product in order to be resolved. Service Attention This issue is responsible by Azure service team. Similar-Issue
Projects
None yet
Development

No branches or pull requests

2 participants