azure-powershell

How can I get the FTP URL for my Azure website via the Management API?

有些话、适合烂在心里 提交于 2019-12-11 06:25:37
问题 I'm trying to get my Azure Web Site's FTP upload address from the Management REST API. Looking at the source code for the Azure SDK Tools, I don't see anything that could help me out, save for a web site property that would be sent via the GetSite action on IWebsitesServiceManagement. Has anyone encountered this problem, and figured out how to get this going? Edit: clarification and links. 回答1: It's there already http://msdn.microsoft.com/en-us/library/windowsazure/dn166996.aspx. Still not

Cannot set “preAuthorizedApplications” object in new App registrations module through Azure Powershell

家住魔仙堡 提交于 2019-12-11 06:03:30
问题 Short Scenrario : A muti tenant front end javascript (React.JS) Web Application calls a multi tenant ASP.NET Core 2.2 WebAPI from the browser. Authentication: ADAL.js in the front end app takes care of getting a token from either AzureAD1 or AzureAD2 or AzureAD3... when the User signs-in (based on the User's original Azure Active Directory). The User gives consent to the front end Web App ( scope: Sign in and read user profile ) which is delegated to the WebAPI too. ( meaning the user does

Unable to Start an Azure VM using Powershell script. We get Parameter set cannot be resolved using the specified named parameters

强颜欢笑 提交于 2019-12-11 05:46:35
问题 We use powershell script to start and stop the VMs using the build job. Please see the screenshot of the build job below It is a simple powershell script to start an VM. The issue is when this job runs, we are getting an error and the build fails. We get Parameter set cannot be resolved using the specified named parameters But when we run it locally using the powershell console, the VMs get started. Please find the error screenshot below Am I missing something here.. Any help would be very

Export azure ad groups membership via powershell

你离开我真会死。 提交于 2019-12-11 04:53:55
问题 I need help in the powershell script. I am looking to get Azure AD, group membership details for multiple groups which are in the CSV file. The format, I am looking to get is: Group Name :SG-Test-Users Members: xyz, abc etc Output needed in this format Please help I tried, below script but it is not giving an output in the format I am looking for. Import-Csv -Path "C:\temp\testgroup.csv" | ForEach-Object {Get-AzureADGroupMember -ObjectId $_.name | select displayname,userprincipalname} |

How to use from a powershell a *.pfx certificate used on build pipeline with the download secure file task

别说谁变了你拦得住时间么 提交于 2019-12-11 04:49:05
问题 I got this problem: I need to connect to an azure subscrition from a powershell script used on a build pipeline, but for security requirements i can't write user and password on the code, so i have a pfx certificate with the credentials. Right now i'm using the task named dowload secure file, to put the certificate on the build. Then i'm trying to access the certificate from the powershell code. I already test the code on my machine, but when i'm trying to use it on the build pipeline i

How can I query “Azure Status” using powershell

99封情书 提交于 2019-12-11 03:38:19
问题 How can I query "Azure Status" using PowerShell? https://azure.microsoft.com/en-in/status/ We have a automation logic in place, and we want to improvise by having a check that checks if the Azure service is having an outage. If there is no outage, then continue with the automation. 回答1: AFAIK, there is no PowerShell or Rest API to get the Azure status. The closest I can find is to get the Resource Health. As this link said, The information provided by Resource Health is more specific than

How can I create an Azure policy that validates Resource Group Names

和自甴很熟 提交于 2019-12-11 01:48:39
问题 I am trying to create an Azure policy which I can assign at the subscription level, and control the naming of the resource groups in the subscription. Policies need to target a resource type or otherwise limit their application, else they apply globally to all resources. What resource type (or other method) can I use to limit my validation to the resource group name only? Here is what I am trying: $definition = New-AzureRmPolicyDefinition -Name resourceGroupNamePatterns -Description "Restrict

Set-AzureRmWebApp changes in Powershell not appearing in Azure Portal

霸气de小男生 提交于 2019-12-11 01:48:12
问题 I am trying to add a virtual application to an Azure website via Powershell. Though the script runs without errors, my changes don't appear in portal.azure.com. Is there another command I need to run at the end to persist the changes? $subscriptionId = "secret" $websiteName = "MyWebsite" $resourceGroupName = "MyResourceGroup" $siteName = "Test" Get-Module AzureRM Login-AzureRmAccount Select-AzureRmSubscription -SubscriptionId $subscriptionId $website = Get-AzureRmWebApp -Name $websiteName

Get storage account of Azure VM

痞子三分冷 提交于 2019-12-11 01:00:07
问题 I am trying to find PowerShell cmdlet which can retrieve information about which storage account Azure VM use. Example, I want to supply name of VM and I would like to see which storage that VM use. Or it will be also good to query specific storage account and see which VMs use this storage account. I am trying following cmdlets but I cannot see details about storage account: Select-AzureSubscription -SubscriptionName "name" Get-AzureVM -Name "name" -ServiceName "name" 回答1: The Get-AzureDisk

auto login Azure powershell

时光怂恿深爱的人放手 提交于 2019-12-10 17:01:40
问题 Every time I open a azure powershell windows is it possible to auto login ? i.e. this command given below should run everytime I open Azure Command window. Get-AzurePublishSettingsFile (path in local machine) or even Add-AzureAccount 回答1: You can actually do it. Follow this process: Open the Azure PowerShell initialization file at "C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\ServiceManagement\Azure\Services\ShortcutStartup.ps1" for 64-bit OS or "C:\Program Files\Microsoft SDKs