I'm writing one Azure Runbook that must clean montly my test environment.
I need delete some Azure Jobs but when I try to retrieve my jobs with Get-AzureRmSchedulerJob command I obtain this error:
Get-AzureRmSchedulerJob -ResourceGroupName MyResourceGroupName -JobCollectionName myJobCollectionName
Get-AzureRmSchedulerJob : The term 'Get-AzureRmSchedulerJob' is not recognized as the name of a cmdlet, function,
script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is
correct and try again.
At line:10 char:1
+ Get-AzureRmSchedulerJob -ResourceGroupName MyResourceGroupName
+ ~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (Get-AzureRmSchedulerJob:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
How can I retrieve my jobs inside Azure Runbook? Using PowerShell this command works. I need cycle all jobs because I cannot delete all jobs.
Thanks