Can you tell me which version of the Azure PowerShell task and version you're using? Are you doing inline or script file?
CI CD Pipeline to deploy Console App as webjobs
CI CD Pipeline to deploy Console App as webjobs
Using the Azure PowerShell task in the release pipeline by passing the Powershell Script file path.
Release is failing with below error
2020-06-15T14:08:47.5855902Z Get-AzureRmResource : The term 'Get-AzureRmResource' is not recognized as the name of a cmdlet, function, script file,
2020-06-15T14:08:47.5893338Z or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and
2020-06-15T14:08:47.5894071Z try again.
2020-06-15T14:08:47.5894514Z At D:\a\r1\a_AskHR-ApprovalService-Gated\CopyEmailFromExchange-drop\DeploymentScripts\AddWebJob.ps1:38 char:19
2020-06-15T14:08:47.5895442Z + $webJobList = Get-AzureRmResource -ResourceGroupName $ResourceGro ...
2020-06-15T14:08:47.5895879Z + ~~~~~~~~~~~~~~~~~~~
2020-06-15T14:08:47.5896344Z + CategoryInfo : ObjectNotFound: (Get-AzureRmResource:String) [], CommandNotFoundException
2020-06-15T14:08:47.5896796Z + FullyQualifiedErrorId : CommandNotFoundException
2020-06-15T14:08:47.5897099Z
2020-06-15T14:08:47.5928917Z Add-Type : Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more
2020-06-15T14:08:47.5934541Z information.
1 answer
Sort by: Most helpful
-
Ryan Hill 26,471 Reputation points Microsoft Employee
2020-06-17T15:42:14.237+00:00