Azure-docs: Script missing steps.

Created on 20 Mar 2019  Â·  6Comments  Â·  Source: MicrosoftDocs/azure-docs

Running these steps "As Is" you encounter an error at Step 4.
First, we should be including this step more prominently :
$resourceGroup = Get-AzureRmResourceGroup -name "YourResourceGroupName"
Then, we cannot define $geoPolicy and create a new one in the same step. This needs to be 2 steps.

  1. New-AzureRmFrontDoorFireWallPolicy -Name "geoPolicyAllowUSOnly" -resourceGroupName $resourceGroup.ResourceGroupName -Customrule $nonUSBlockRule -Mode Prevention -EnabledState Enabled

4b. $geoPolicy = Get-AzureRmFrontDoorFireWallPolicy -resourceGroupName $resourceGroup.ResourceGroupName -name "geoPolicyAllowUSOnly"

Finally, you will notice "-resourceGroupName $resourceGroup.ResourceGroupName"
There may be a better way to refer to the "-name" of the resource group than this, by re-writing the $resourceGroup argument.
I could not figure it out. In any case, the script fails. The documentation needs updated.


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

cxp doc-bug frontdoosvc in-progress triaged

All 6 comments

@n0ttsweet Thank you for pointing this out . We will investigate and update further.

@n0ttsweet , Thanks for your feedback. We are working on it to update the document.

@n0ttsweet , The document has been enhanced and updated. We really appreciate your feedback.We are closing this issue for now.If there are further questions regarding this matter, please reply and we will gladly continue the discussion.

Whoever edited this documentation, seems to have

  1. converted it to Azure CLI.
  2. Not mentioned this fact.
  3. Did not make any of the necessary changes that I outlined in this issue.
  4. Made the article fail from step one. (made it worse than before.)

Just a side note, the doc is using PowerShell. The lastest module now is Az instead of AzureRM

But it could still be broken. I will let @SubhashVasarapu-MSFT dig deeper into that.

Ahh, I have not updated my module.
Thank you, I will do that.
It may work now, if the commands are recognized by the new module update. There were 2 that failed prior.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Favna picture Favna  Â·  3Comments

JamesDLD picture JamesDLD  Â·  3Comments

Ponant picture Ponant  Â·  3Comments

monteledwards picture monteledwards  Â·  3Comments

paulmarshall picture paulmarshall  Â·  3Comments