Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
Springstone committed Dec 9, 2024
1 parent 33f0dae commit c49661c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions eslzArm/prerequisites/deployPrerequisites.json
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@
$result = Invoke-AzRestMethod -Method POST -Uri \"https://management.azure.com/providers/Microsoft.Management/managementGroups/$eslzRootName/providers/Microsoft.Network/register?api-version=2021-04-01\"
$count++
Start-Sleep -Seconds 30
Write-Output 'MG RP Register - Status Code: ' $result.StatusCode ' Count: ' $count
Write-Host 'MG RP Register - Status Code: ' $result.StatusCode ' Count: ' $count
} while ($result.StatusCode -ne 200 -and $count -lt 10)

#Register all resource providers
Expand All @@ -175,7 +175,8 @@

foreach ($sub in $subs) {
Select-AzSubscription -SubscriptionId $sub.id
Get-AzResourceProvider -ProviderNamespace $rps | Register-AzResourceProvider
Write-Host 'Registering resource providers for subscription: ' $sub.id
Get-AzResourceProvider -ProviderNamespace $rps | where {$_.RegistrationState -ne \"Registered\"} | Register-AzResourceProvider
}
"
},
Expand Down

0 comments on commit c49661c

Please sign in to comment.