Skip to content

Commit 2b5b55a

Browse files
committed
AzureRM backward compatibility; Rename diagnostic extension name
1 parent fb8bdf0 commit 2b5b55a

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

CanaryValidator/Canary.Tests.ps1

+3-1
Original file line numberDiff line numberDiff line change
@@ -569,7 +569,9 @@ while ($runCount -le $NumberOfIterations)
569569

570570
Invoke-Usecase -Name 'RegisterResourceProviders' -Description "Register resource providers" -UsecaseBlock `
571571
{
572-
("Microsoft.Storage", "Microsoft.Compute", "Microsoft.Network", "Microsoft.KeyVault") | ForEach-Object {Get-AzureRmResourceProvider -ProviderNamespace $_} | Register-AzureRmResourceProvider -Force
572+
$parameters = @{}
573+
if ((Get-Module AzureRM -ListAvailable).Version -le "1.2.10") {$parameters = @{"Force" = $True}}
574+
("Microsoft.Storage", "Microsoft.Compute", "Microsoft.Network", "Microsoft.KeyVault") | ForEach-Object {Get-AzureRmResourceProvider -ProviderNamespace $_} | Register-AzureRmResourceProvider @parameters
573575
$sleepTime = 0
574576
while($true)
575577
{

CanaryValidator/azuredeploy.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -648,7 +648,7 @@
648648
{
649649
"apiVersion": "[variables('apiVersion')]",
650650
"type": "Microsoft.Compute/virtualMachines/extensions",
651-
"name": "[concat(concat(variables('VMNamePrefix'), '1'),'/Microsoft.Insights.VMDiagnosticsSettings')]",
651+
"name": "[concat(concat(variables('VMNamePrefix'), '1'),'/VMDiagnosticsSettings')]",
652652
"location": "[variables('location')]",
653653
"dependsOn": [
654654
"[concat('Microsoft.Storage/storageAccounts/', variables('storageAccountName3'))]",

CanaryValidator/azuredeploy.nolinux.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -547,7 +547,7 @@
547547
{
548548
"apiVersion": "[variables('apiVersion')]",
549549
"type": "Microsoft.Compute/virtualMachines/extensions",
550-
"name": "[concat(concat(variables('VMNamePrefix'), '1'),'/Microsoft.Insights.VMDiagnosticsSettings')]",
550+
"name": "[concat(concat(variables('VMNamePrefix'), '1'),'/VMDiagnosticsSettings')]",
551551
"location": "[variables('location')]",
552552
"dependsOn": [
553553
"[concat('Microsoft.Storage/storageAccounts/', variables('storageAccountName3'))]",

0 commit comments

Comments
 (0)