Category "azure-powershell"

Powershell - Azure AD Application Registration - how to set ID tokens?

Background Information I have two separate PowerShell scripts. One uses an ARM template to deploy a function app, along with storage accounts etc. It runs unde

How to copy connection security firewall rules,SSL,TLS from one azure DB for mysql to another azure DB for my sql server using powershell

I have restored Azure Database for MySQL single server using powershell script below. Now, post restore the DB I had to copy all the firewall rules and other se

Disable multiple logic apps across different Resource Groups

I have a use case where I want to disable the old Logic Apps that our company is no longer using. All the Logic App are present in different environments and ne

How to update all Azure Powershell Az modules?

The Azure Powershell Az module comes with an assortment of modules such as Az.Accounts, Az.Aks, etc. Is it possible to update all these Az.* modules at once?

Get a list of all of an Azure Function App's functions & status

With Azure Powershell, how do you get a list of all of a Function App's functions and their respective status (status at the function level, not FunctionApp lev

Get-AzKeyVault -InRemovedState call from Azure Function returns null even after long wait

Here's the sequence of actions performed inside Azure powershell function - if (Get-AzKeyVault -VaultName $name) { #This should Delete the KeyVault and put

How to Get Azure AD Object by Object ID Using Azure CLI

In the Azure Portal, one can look-up an Azure AD object based on the Object ID as shown below: Is it possible to retrieve an Azure AD object by the Object ID u

Invoke-Sqlcmd with AAD authentication

In an Azure DevOps 'release pipeline', I provision Azure resources - including SQLServer databases - and try to configure access to databases using managed iden

How to enable Update Management for an Azure Automation Account programmatically?

I'm currently using Terraform and bits of Powershell to automate all of my infrastructure and I'm seeking a fully automated means to configure update management

Create replica of Azure DB for my SQL Server using powershell

While creating replica of Azure DB for my SQL Server using powershell getting the below error. Please help me to fix. Command to create replica of DB server: 1s

How to pass Json parameters to powershell script

I would like to pass Json data to Powershell script. PowerShell script: Get-AzMySqlFirewallRule -ResourceGroupName "dev" -ServerName "dev-DB-Server" | Out-File

Get-AzureADAuditSignInLogs returning $null in Automation Accounts

I have a simple script to get the last sign in details for each user in Azure. When running the script from Visual Studio, it all runs fine with no errors. Afte

Resume Azure VM backup using powershell script after disabling backup

I would like to resume my backup after disabling backup. Used the below commands for disabling and enabling. Disabling backup :Disable-AzRecoveryServicesBackupP

Connect-AzAccount : The term 'Connect-AzAccount' is not recognized as the name of a cmdlet, function, script file, or operable program

I am trying to execute the following PowerShell script in Azure DevOps pipeline by using PowerShell task with inline mode. $clientId= "xxxxxxxxx" $clientSecre

How can you use secret variables from a linked variable group in an Azure Powershell task in an Azure Release pipeline?

I have an Azure Release pipeline that I've built using the GUI in Azure DevOps. There is a stage that has a linked variable group (Release scope) with a secret

How to start or stop appservices in Azure

I want to stop my appservices at midnight and want to start them at morning.So i came across two things , runbooks and webjobs .So first i included a runbook wh