Questions tagged [azure-automation]

Azure Automation handles the creation, deployment, monitoring, and maintenance of Azure resources and third-party applications. It uses uses Windows PowerShell scripts or Azure Runbooks to achieve this.

In Azure Automation, Windows PowerShell scripts or Azure Runbooks can handle the creation, deployment, monitoring, and maintenance of Azure resources and third-party applications. These scripts can run in the cloud, on-premises, or on Azure/AWS/Google VMs.

908 questions
17
votes
8 answers

Specflow - GenerateFeatureFileCodeBehindTask has failed unexpectedly

I have a problem with SpecFlow. We are using Azure Devops and when I build solution on my local machine it works perfectly but during Azure Devops build I am getting following…
aj_2017
  • 171
  • 1
  • 1
  • 5
11
votes
2 answers

How to run stored procedure using Azure Automation?

I´m really new to the Azure platform and maybe this is a dumb question but i haven´t manage to find information about this topic. I really need help with this. I'm deploying a database used by a web service for a university project. In this database…
10
votes
2 answers

Using Empty/Optional Parameters in Azure ARM Template

I'm having issues setting up an ARM Template for Azure Web Apps in that I can't add ConnectionString parameters where it sets the values if the parameters are set, but leave blank (default) if the parameters aren't set. Here is how it looks in the…
8
votes
1 answer

How to AcquireToken with PromptBehavior in the latest Microsoft.IdentityModel.Clients.ActiveDirectory

In the older versions of Microsoft.IdentityModel.Clients.ActiveDirectory there is AcquireToken with PromptBehavior parameter var context = new AuthenticationContext("https://login.windows.net/tenantId"); var result = context.AcquireToken(clientId:…
kumar
  • 8,207
  • 20
  • 85
  • 176
7
votes
4 answers

Set-AzureRmContext error when executed within an Azure Automation Runbook

Update: Seems like someone else had the same issue and reported it. I am facing an issue with a simple PowerShell script when invoking it from an Azure Automation Runbook. The same piece of code works flawless when running it locally. I have added…
Martin Brandl
  • 56,134
  • 13
  • 133
  • 172
6
votes
3 answers

Does Azure Automation support Write-Information?

I want to write info logs into Azure Automation job logs. I've created the simple PowerShell runbook $InformationPreference = "Continue" Write-Information "Hello info" Write-Verbose "Hello Verbose" Write-Warning "Hello warning" Write-Error "Hello…
Vasyl Zvarydchuk
  • 3,789
  • 26
  • 37
6
votes
0 answers

Import pfx certificate in CurrentUser Personal Store from DSC Script resource + Automation does not work

I am working on automating the deployment of our product on Azure VMs. I am using Powershell DSC with Azure automation to provision the VM. One of the requirement is to import a pfx certificate to CurrentUser/My for a user on the VM. I am trying to…
coder_andy
  • 376
  • 1
  • 3
  • 17
6
votes
2 answers

ARM listKeys() Function - How to retrieve OMS/OpsInsight Workspace keys?

As part of a template I want to retrieve the SharedKeys of an OMS / Operational Insights Workspace, rather than having to pass it in as a parameter. Is this possible? I'm following the documentation here It does not appear that the…
6
votes
2 answers

Azure automation powershell, not work int input parameter

I use azure automation, and have code like this workflow Report { param ( [parameter(Mandatory=$True)] [string] $Name, [parameter(Mandatory=$true)] [Int] $MyCount ) inlinescript { …
pasha
  • 566
  • 5
  • 19
5
votes
3 answers

Can custom console application be executed in Azure (PowerShell) Runbook?

Can I use my own/custom console application in Azure Runbook (PowerShell or any other)? When I try to run my own console application (after retrieving it from Azure Storage), it fails. When I try to execute it simply by: .\myapp.exe I…
Martin Prikryl
  • 188,800
  • 56
  • 490
  • 992
5
votes
2 answers

Azure Runbook - Get a file from Azure File System Storage

I am creating a Azure workflow runbook wherein I have to get a file from Azure File System Storage and publish that to a azure web app. I tried with New-PSDrive but that command is not supported in runbook (even InlineScript doesn't work). Could…
Adavesh
  • 557
  • 5
  • 9
5
votes
2 answers

Printing messages from SQL in Azure Automation powershell script doesn't work

I've created a sample Azure Automation Powershell Runbook. I'm trying to execute a SQL command and then print the messages from that command into Workbook output. My code is taken from Capturing InfoMessage Output from SQL Server using PowerShell…
Mikhail Shilkov
  • 34,128
  • 3
  • 68
  • 107
5
votes
2 answers

Error on deployment Azure Automation Variable Assets

When I try to deploy variable to Azure Automation assets, I got and error and can't deploy my resource. Suppose this template { "name": "myVariable", "type": "Microsoft.Automation/automationAccounts/variables", "apiVersion": "2015-10-31", …
5
votes
2 answers

Invoke-RestMethod - how to pass "ETag does not represent the latest state of the resource."

Question How to pass the exception having the following message? Invoke-RestMethod : {"Message":"ETag does not represent the latest state of the resource."} Seeing the reference, I think "passing If-Match: "*" header" should be a key, but don't…
grantaka36
  • 277
  • 1
  • 2
  • 14
5
votes
2 answers

Create an automation job to execute azure runbook using REST API

In this link (Create azure automation account using REST api from java) I'd asked about how to create an automation account in order to create runbook. Now, that I've created an automation account and also a runbook which is published, I want to…
devd
  • 370
  • 10
  • 28
1
2 3
60 61