As this task is updated to newer versions of the AzureRM module, builds dependent on the previous version can break. It would be nice to be able to "pin" the task to a particular version of the AzureRM module via a setting in the task UI.
Here's a uservoice link requesting the same:
https://visualstudio.uservoice.com/forums/330519-team-services/suggestions/12840342-update-azure-powershell-on-host-agents-of-visual-s
Hi @pauldalyii , currently this is a work in progress. I will update you on this thread when the hosted agents get updated with the latest Azure PowerShell versions.
Thanks @arjgupta.
I'm not sure I was clear enough though. I definitely want the Azure PowerShell task to _support_ updating to the latest Azure PowerShell modules. However, my ask is that I am able to _specify_ which version of the module I want to use on a _task by task_ basis. I don't want the verison of AzureRM to change on me between builds because the VSTS upgraded. I want to have to _manually specify_ the version I want to be using for a given task.
This is akin to nuget package management. I don't always want the latest version. I want to specify the versions of the nuget packages on which my app depends.
Thanks again for your help!
Sorry, to expand on this...
I really need both the AzureRM module _and_ the AzureAD modules to be loaded in the Azure PowerShell task - and I'd like to set both of their module versions.
There is some overlap in functionality between the two, but there's a lot missing from AzureRM in terms of AD functionality.
I can open an new issue if you'd like.
Hi @pauldalyii , currently there are no plans on supporting the selection of both Azure and AzureRM module versions separately. However, we have added support for specifying Azure PowerShell version in the major version 2 of the task. We have also updated VS2017 Hosted Pool Agent for supporting multiple azure powershell versions. From the dropdown associated with the “Azure PowerShell Version” input, select the option “Specify other version” and then in the “Preferred Azure PowerShell Version” input, you can specify ‘4.2.1’ or '3.8.0'
Would it be possible to have a second VSTS Task for the AzureAD module, that would function in the same way that the AzureRM task does today instead of overloading the Azure Powershell task to do both?
Thanks!
@pauldalyii, can you please elaborate, "second task for AzureAD module". Are you referring to having another Azure PowerShell task wherein you can specify both AzurePS and AzureAD versions or just AzureAD version? Can you install AzureRD as part of your powershell script?
Right now, we don't have plans to add additional AzurePS task.
Hi @RoopeshNair, At first I asked for the current Azure PowerShell task to load both the AzureRM and AzureAD modules and authenticate both of them using the Azure service connection selected for the task:
Sorry, to expand on this...
I really need both the AzureRM module and the AzureAD modules to be loaded in the Azure PowerShell task - and I'd like to set both of their module versions.
There is some overlap in functionality between the two, but there's a lot missing from AzureRM in terms of AD functionality.
I can open an new issue if you'd like.
However @arjgupta indicated that there were no plans to do that:
Hi @pauldalyii , currently there are no plans on supporting the selection of both Azure and AzureRM module versions separately.
So as a follow up, I asked that in absence of loading both modules in the same task, would you be able to create a separate task that loads just the AzureAD module and authenticates the module using the Azure service connection for that new task type:
Would it be possible to have a second VSTS Task for the AzureAD module, that would function in the same way that the AzureRM task does today instead of overloading the Azure Powershell task to do both?
Thanks!
I'd prefer one Azure PowerShell VSTS task because then I could write a script that leverages both Azure modules (AzureAD and AzureRM) and only have one VSTS task to work with both. I'd settle for doing AzureAD stuff in one task and passing that information along to a second AzureRM task. This is less desirable because I don't really want to deal with the ceremony of passing output of one task to the input of another if I can just do it all w/in one script, but that is nitpicky.
Ultimately I'm asking for this because I don't know how to use the AzureAD module using the credentials I've associated with Release Management.
Thanks again!
@pauldalyii , the current task also supports loading the Azure Module, you have to use a classic endpoint for it to be imported. And for the Azure RM module to be loaded , you need to use an AzureRM endpoint.
I'm sorry... I think there is some confusion.
When I refer to the AzureAD vs AzureRM PowerShell modules, I'm not referring to Azure classic vs AzureRM.
I'm referring to AzureAD vs AzureRM
Ideally I want a singular VSTS task that signs me into both AzureAD and AzureRM, but alternatively I just want an additional VSTS task that signs me into the AzureAD module under the context of the Azure service connection selected for that task.
Thanks for considering this!
Should I open this as a separate issue?
re-opening for @arjgupta to answer that question
Hi @pauldalyii , AzureAD is not supported in the Azure PowerShell task. Adding @RoopeshNair to look into this enhancement.
Right, my request is to either:
@RoopeshNair, have you had a chance to look into this? is this something you'd consider adding? it would eliminate a number of manual steps from my release definition (my manual steps tell me to run AzureAD scripts on my local dev PC).
Thanks!
@pauldalyii, we will consider adding support for AzureAD as part of AzurePS task to backlog. However, it will be a while before we can get to it (>6 months).
Ok, thank you!
any update on this? I am facing very similar requirements as @pauldalyii
@pauldalyii - we haven't gotten to this. At present we are focussed on issues affecting a broader set of customers. We know this is important for you. We will continue to monitor it.
for my scneario, all I needed from AzureAD module now exists in AzureRM module. but the Module version is 6.0.1 and the VSTS taks always uses 5.1.1
So far I could not find a way to update the module - is this somehow possible?
Most helpful comment
for my scneario, all I needed from AzureAD module now exists in AzureRM module. but the Module version is 6.0.1 and the VSTS taks always uses 5.1.1
So far I could not find a way to update the module - is this somehow possible?