Getting error while trying to run Test-AzResourceGroupDeployment

Pallab Chakraborty 401 Reputation points
2020-09-09T12:18:46.643+00:00

I want to validate my ARM template and so i run the below command :

Test-AzResourceGroupDeployment -ResourceGroupName PallabDev -TemplateFile .\UBUNTU_DEV.json -TemplateParameterFile .\UBUNTU_DEV_Param.json

I get the below error with the above command :

Test-AzResourceGroupDeployment : Invalid property identifier character: #. Path '', line 2, position
2.
At line:1 char:1

  • Test-AzResourceGroupDeployment -ResourceGroupName PallabDev -Template ...
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  • CategoryInfo : CloseError: (:) [Test-AzResourceGroupDeployment], JsonReaderException
  • FullyQualifiedErrorId : Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation.TestAzu
    reResourceGroupDeploymentCmdlet

Any Idea why this error is coming and how to fix it.

Not Monitored
Not Monitored
Tag not monitored by Microsoft.
36,262 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Pallab Chakraborty 401 Reputation points
    2020-09-26T01:06:25.293+00:00

    Hi, i was able to fix it, you were right, there was an issue with my .JSON file. I was able to rectify it successfully. Sorry for the late reply. Thanks

    0 comments No comments