Share via

Azure Automation PowerShell

Mukesh Kumar 0 Reputation points
2023-08-17T12:10:19.7933333+00:00
#az login --service-principal # -ServicePrincipal 
az login --identity

It's not working.
 I am not sure which module I should import
error is as follows





Azure Automation
Azure Automation

An Azure service that is used to automate, configure, and install updates across hybrid environments.

0 comments No comments

1 answer

Sort by: Most helpful
  1. Gordon Byers 7,165 Reputation points
    2023-08-17T12:14:45.0833333+00:00

    OOB Azure Automation PowerShell does not leverage the Azure CLI. You should be using the Azure Powershell modules.

    eg. https://github.com/finoops/aks-cluster-changestate/blob/cae3cf1987d5030d665f81c8fbd9530f426845eb/aks-cluster-changestate.ps1#L41C22-L41C22

    See this question for a workaround to use the Az CLI.

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.