Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update/Add PowerShell Az Module v5.6.0 #2867

Closed
7 tasks done
cognitionIT opened this issue Mar 7, 2021 · 14 comments
Closed
7 tasks done

Update/Add PowerShell Az Module v5.6.0 #2867

cognitionIT opened this issue Mar 7, 2021 · 14 comments

Comments

@cognitionIT
Copy link

cognitionIT commented Mar 7, 2021

Tool information

  • Tool name: PowerShell Az Module
  • Add or update? Update
  • Desired version: 5.6.0

Area for Triage:

Question, Bug, or Feature?:
Feature

Virtual environments affected

  • Ubuntu 16.04
  • Ubuntu 18.04
  • Ubuntu 20.04
  • macOS 10.15
  • macOS 11.0
  • Windows Server 2016 R2
  • Windows Server 2019

Can this tool be installed during the build?
According to this link, the PowerShell Az module v5.6.0+ has built-in support for resource deployments in Azure, using a bicep template file instead of a JSON template file. Unfortunately I cannot use Update-Module to update the module myself to the latest version as it was not installed using Install-Module (so it cannot be Updated via an inline script using the PowerShell GitHub Action).

@Darleev
Copy link
Contributor

Darleev commented Mar 7, 2021

Hello @cognitionIT,
In our scripts, we use the automatic installation of the latest stable version of the az module. So, the version of the module should be updated after the next image rollout(most probably during this week).
I'll keep you informed.

@Darleev Darleev added the awaiting-deployment Code complete; awaiting deployment and/or deployment in progress label Mar 7, 2021
@cognitionIT
Copy link
Author

Thank you @Darleev for the quick response, getting the latest stable version in the image rollout is fast enough for me, so it makes me happy to know I'll have some GitHub Actions fun to look forward to next weekend :-)

@Darleev
Copy link
Contributor

Darleev commented Mar 8, 2021

Hello @cognitionIT,
We've received a new update, that az module update will be delayed due to code refactoring. We are waiting for the following PRs:
#2827
#2828
When PRs are completed, we will definitely upgrade az module to the latest stable version.
I'll keep you informed.

@Darleev Darleev removed the awaiting-deployment Code complete; awaiting deployment and/or deployment in progress label Mar 9, 2021
@cognitionIT
Copy link
Author

Thanks for letting me know @Darleev, I'll try to be patient ;-)

@krokofant
Copy link

I added this as a workaround for now

$minAzModuleVersion = '5.6.0'
if(!(Test-Path "C:\Modules\az_$minAzModuleVersion")) {
  Install-Module -Name Az -AllowClobber -Scope CurrentUser -Force
  Save-Module -Path "C:\Modules\az_$minAzModuleVersion" -Name Az -RequiredVersion $minAzModuleVersion -Force -ErrorAction Stop
}
$env:PSModulePath = "C:\Modules\az_$($minAzModuleVersion);$($env:PSModulePath)"
Import-Module Az

@cognitionIT
Copy link
Author

I added this as a workaround for now

$minAzModuleVersion = '5.6.0'
if(!(Test-Path "C:\Modules\az_$minAzModuleVersion")) {
  Install-Module -Name Az -AllowClobber -Scope CurrentUser -Force
  Save-Module -Path "C:\Modules\az_$minAzModuleVersion" -Name Az -RequiredVersion $minAzModuleVersion -Force -ErrorAction Stop
}
$env:PSModulePath = "C:\Modules\az_$($minAzModuleVersion);$($env:PSModulePath)"
Import-Module Az

Thanks for this workaround, I'll add it to the workflow and test it in a couple of hours as I'd rather run on the latest windows runner than a self-hosted runner :-)

@ricohomewood
Copy link

Az 5.6.0 has a major P0 bug in Az.Automation that has now been fixed in 5.7.0 which has now been released :Azure/azure-powershell#14431 . Do we know when the Hosted Agents will install the real latest version of the Az powershell module? Currently they are still on 5.5.0 as their defined latest which is now 2 versions behind.

@maxim-lobanov
Copy link
Contributor

Hello everyone!
No need to wait, both azure/powershell (GitHub Actions task) and AzurePowerShell (Azure DevOps) were recently upgraded and can install any version of Az on-flight with 1-2 seconds delay.

    steps:
    - task: AzurePowerShell@5
      inputs:
        azureSubscription: '<>'
        ScriptType: 'InlineScript'
        preferredAzurePowerShellVersion: '5.7.0'

@krokofant
Copy link

Now 5.7 is out which also fixes a critical issue about nested bicep files.

@miketimofeev
Copy link
Contributor

@cognitionIT @krokofant we've added version 5.7.0 to all the images and started a rollout. It will be finished in 3-4 days.

@miketimofeev miketimofeev added the awaiting-deployment Code complete; awaiting deployment and/or deployment in progress label Apr 12, 2021
@miketimofeev
Copy link
Contributor

@cognitionIT the rollout is finished for all the images.
I'm going to close the issue. Please feel free to contact us if you have any concerns.
Thank you!

@miketimofeev miketimofeev removed the awaiting-deployment Code complete; awaiting deployment and/or deployment in progress label Apr 15, 2021
@brwilkinson
Copy link

Is there a standard procedure in place to request an AZ Module version update ? Or is it best to just open a new issue each x months Etc. ?

Does the team have any plans to always stay N-1 or something on the latest version of AZ ?

@miketimofeev
Copy link
Contributor

@brwilkinson we tend to manually update Az versions to avoid critical bugs that can be introduced in the new versions. Please create an issue if you'd like the new version to be added

@brwilkinson
Copy link

Thanks @miketimofeev sounds good.

#3558

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants