From 125779e366e5209c98fe969ae39286be0ad8ec82 Mon Sep 17 00:00:00 2001 From: Shivangi Date: Fri, 13 Dec 2019 11:18:10 +0530 Subject: [PATCH] Added Az 3.1.0 in hosted image --- images/linux/Ubuntu1604-README.md | 1 + images/linux/Ubuntu1804-README.md | 1 + .../scripts/installers/1604/azpowershell.sh | 9 +++++- .../scripts/installers/1804/azpowershell.sh | 7 +++++ images/win/Windows2016-Readme.md | 28 +++++++++++++++++++ images/win/Windows2019-Readme.md | 28 +++++++++++++++++++ .../Installers/Install-AzureModules.ps1 | 2 +- 7 files changed, 74 insertions(+), 2 deletions(-) diff --git a/images/linux/Ubuntu1604-README.md b/images/linux/Ubuntu1604-README.md index 0fae6301..5a333251 100644 --- a/images/linux/Ubuntu1604-README.md +++ b/images/linux/Ubuntu1604-README.md @@ -231,6 +231,7 @@ the - Az Module (1.6.0) - Az Module (2.3.2) - Az Module (2.6.0) +- Az Module (3.1.0) - Cached container images - node:10 (Digest: sha256:be69034700545030c110f67ae22e0584ddd59eeb2af81e4bd7f16f3ba5fa93a6) - node:12 (Digest: sha256:88ee7d2a5e18d359b4b5750ecb50a9b238ab467397c306aeb9955f4f11be44ce) diff --git a/images/linux/Ubuntu1804-README.md b/images/linux/Ubuntu1804-README.md index 337634dd..44a6af1c 100644 --- a/images/linux/Ubuntu1804-README.md +++ b/images/linux/Ubuntu1804-README.md @@ -223,6 +223,7 @@ the - Az Module (1.6.0) - Az Module (2.3.2) - Az Module (2.6.0) +- Az Module (3.1.0) - Cached container images - node:10 (Digest: sha256:be69034700545030c110f67ae22e0584ddd59eeb2af81e4bd7f16f3ba5fa93a6) - node:12 (Digest: sha256:88ee7d2a5e18d359b4b5750ecb50a9b238ab467397c306aeb9955f4f11be44ce) diff --git a/images/linux/scripts/installers/1604/azpowershell.sh b/images/linux/scripts/installers/1604/azpowershell.sh index c8211f68..73d22945 100644 --- a/images/linux/scripts/installers/1604/azpowershell.sh +++ b/images/linux/scripts/installers/1604/azpowershell.sh @@ -13,6 +13,7 @@ sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_1.6.0 -Requi sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_2.3.2 -RequiredVersion 2.3.2 -Force' sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_2.6.0 -RequiredVersion 2.6.0 -Force' sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_2.8.0 -RequiredVersion 2.8.0 -Force' +sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_3.1.0 -RequiredVersion 3.1.0 -Force' # Run tests to determine that the software installed as expected echo "Testing to make sure that script performed as expected, and basic scenarios work" @@ -40,6 +41,11 @@ if ! pwsh -Command '$actualPSModulePath = $env:PSModulePath ; $env:PSModulePath if (!(get-module -listavailable -name Az.accounts)) { Write-Host "Az Module was not installed"; $env:PSModulePath = $actualPSModulePath; exit 1 } + $env:PSModulePath = $actualPSModulePath + $actualPSModulePath = $env:PSModulePath ; $env:PSModulePath = "/usr/share/az_3.1.0:" + $env:PSModulePath; + if (!(get-module -listavailable -name Az.accounts)) { + Write-Host "Az Module was not installed"; $env:PSModulePath = $actualPSModulePath; exit 1 + } $env:PSModulePath = $actualPSModulePath'; then exit 1 fi @@ -50,4 +56,5 @@ DocumentInstalledItem "Az Module (1.0.0)" DocumentInstalledItem "Az Module (1.6.0)" DocumentInstalledItem "Az Module (2.3.2)" DocumentInstalledItem "Az Module (2.6.0)" -DocumentInstalledItem "Az Module (2.8.0)" \ No newline at end of file +DocumentInstalledItem "Az Module (2.8.0)" +DocumentInstalledItem "Az Module (3.1.0)" \ No newline at end of file diff --git a/images/linux/scripts/installers/1804/azpowershell.sh b/images/linux/scripts/installers/1804/azpowershell.sh index ca41c380..73d22945 100644 --- a/images/linux/scripts/installers/1804/azpowershell.sh +++ b/images/linux/scripts/installers/1804/azpowershell.sh @@ -13,6 +13,7 @@ sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_1.6.0 -Requi sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_2.3.2 -RequiredVersion 2.3.2 -Force' sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_2.6.0 -RequiredVersion 2.6.0 -Force' sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_2.8.0 -RequiredVersion 2.8.0 -Force' +sudo pwsh -Command 'Save-Module -Name Az -LiteralPath /usr/share/az_3.1.0 -RequiredVersion 3.1.0 -Force' # Run tests to determine that the software installed as expected echo "Testing to make sure that script performed as expected, and basic scenarios work" @@ -40,6 +41,11 @@ if ! pwsh -Command '$actualPSModulePath = $env:PSModulePath ; $env:PSModulePath if (!(get-module -listavailable -name Az.accounts)) { Write-Host "Az Module was not installed"; $env:PSModulePath = $actualPSModulePath; exit 1 } + $env:PSModulePath = $actualPSModulePath + $actualPSModulePath = $env:PSModulePath ; $env:PSModulePath = "/usr/share/az_3.1.0:" + $env:PSModulePath; + if (!(get-module -listavailable -name Az.accounts)) { + Write-Host "Az Module was not installed"; $env:PSModulePath = $actualPSModulePath; exit 1 + } $env:PSModulePath = $actualPSModulePath'; then exit 1 fi @@ -51,3 +57,4 @@ DocumentInstalledItem "Az Module (1.6.0)" DocumentInstalledItem "Az Module (2.3.2)" DocumentInstalledItem "Az Module (2.6.0)" DocumentInstalledItem "Az Module (2.8.0)" +DocumentInstalledItem "Az Module (3.1.0)" \ No newline at end of file diff --git a/images/win/Windows2016-Readme.md b/images/win/Windows2016-Readme.md index 7be14814..72943829 100644 --- a/images/win/Windows2016-Readme.md +++ b/images/win/Windows2016-Readme.md @@ -353,6 +353,34 @@ This version is saved but not installed _Location:_ C:\Modules\azurerm_6.7.0\AzureRM\6.7.0\AzureRM.psd1 +## Az Powershell modules + +#### 1.0.0 + +This version is saved but not installed +_Location:_ C:\Modules\az_1.0.0\Az\1.0.0\Az.psd1 + +#### 1.6.0 + +This version is saved but not installed +_Location:_ C:\Modules\az_1.6.0\Az\1.6.0\Az.psd1 + +#### 2.3.2 + +This version is saved but not installed +_Location:_ C:\Modules\az_2.3.2\Az\2.3.2\Az.psd1 + +#### 2.6.0 + +This version is saved but not installed +_Location:_ C:\Modules\az_2.6.0\Az\2.6.0\Az.psd1 + +#### 3.1.0 + +This version is saved but not installed +_Location:_ C:\Modules\az_3.1.0\Az\3.1.0\Az.psd1 + + ## TLS12 _Version:_ 1.2
diff --git a/images/win/Windows2019-Readme.md b/images/win/Windows2019-Readme.md index a072e5ae..ed32298c 100644 --- a/images/win/Windows2019-Readme.md +++ b/images/win/Windows2019-Readme.md @@ -325,6 +325,34 @@ This version is saved but not installed _Location:_ C:\Modules\azurerm_6.7.0\AzureRM\6.7.0\AzureRM.psd1 +## Az Powershell modules + +#### 1.0.0 + +This version is saved but not installed +_Location:_ C:\Modules\az_1.0.0\Az\1.0.0\Az.psd1 + +#### 1.6.0 + +This version is saved but not installed +_Location:_ C:\Modules\az_1.6.0\Az\1.6.0\Az.psd1 + +#### 2.3.2 + +This version is saved but not installed +_Location:_ C:\Modules\az_2.3.2\Az\2.3.2\Az.psd1 + +#### 2.6.0 + +This version is saved but not installed +_Location:_ C:\Modules\az_2.6.0\Az\2.6.0\Az.psd1 + +#### 3.1.0 + +This version is saved but not installed +_Location:_ C:\Modules\az_3.1.0\Az\3.1.0\Az.psd1 + + ## TLS12 _Version:_ 1.2
diff --git a/images/win/scripts/Installers/Install-AzureModules.ps1 b/images/win/scripts/Installers/Install-AzureModules.ps1 index c1f7956a..24f175a7 100644 --- a/images/win/scripts/Installers/Install-AzureModules.ps1 +++ b/images/win/scripts/Installers/Install-AzureModules.ps1 @@ -162,7 +162,7 @@ $extractLocation = "C:\Modules" $azurePsUri = @( "https://vstsagenttools.blob.core.windows.net/tools/azurepowershellmodules/AzurePSModules.M157.20190808.27979.zip", "https://vstsagenttools.blob.core.windows.net/tools/azurepowershellmodules/AzureRmPSModules.M157.20190808.27379.zip", - "https://vstsagenttools.blob.core.windows.net/tools/azurepowershellmodules/AzPSModules.M158.20190903.19326.zip" + "https://vstsagenttools.blob.core.windows.net/tools/azurepowershellmodules/AzPSModules.M163.20191211.17769.zip" ) $azureRMModulePath = "C:\Modules\azurerm_2.1.0"