azure-resource-manager

Azure ARM Template and PowerShell Module

那年仲夏 提交于 2019-12-11 14:44:49
问题 I Have a module published on Powrshell Gallery and I want to deploy this module with Azure ARM Template. And I did not find how! Here my template : "resources": [ { "name": "[variables('automationAccountName')]", "type": "Microsoft.Automation/automationAccounts", "apiVersion": "2015-10-31", "location": "[parameters('AutomationLocation')]", "tags": { "displayName": "Compte Automation" }, "properties": { "sku": { "name": "Basic", "family": "B" } }, "resources": [ { "name": "[variables(

Internal server error when deploying ARM Template

女生的网名这么多〃 提交于 2019-12-11 14:18:35
问题 I am deploying an arm template that contains the following resources Microsoft.Storage/storageAccount Microsoft.Sql/servers Microsoft.Sql/servers/auditPolicies Now everything worked until I started changing the values for the auditPolicies object. Here are the steps I took until the InternalServerError occurred. Added the auditState property and set its value to Disabled . Deployment Successful. Changed the auditState property to Enabled . Deployment failed. Error states that the

Add VM to existing vnet and subnet

半城伤御伤魂 提交于 2019-12-11 10:45:54
问题 I am using a json file to create a VM. Everything works good with exception of the vnet and subnet, every time I created a new VM, it creates a new vnet and subnet, how can I create VMs and assign them to an existing vnet and subnet using a json template? 回答1: Have you tried below sample template https://github.com/Azure/azure-quickstart-templates/tree/master/201-vm-different-rg-vnet you should be able to update your ARM template to create your VM into an existing VNet. 回答2: am assuming by

Import databases using Azure ARM template

南笙酒味 提交于 2019-12-11 10:43:44
问题 Using Azure ARM template, you can create Azure SQL databases. But how can you deploy table schemas or import databases. 回答1: The answer and a sample ARM template can be found at https://stackoverflow.com/questions/34987911/import-a-database-using-azurerm-powershell/34989636#= The following is an example of using a public container instead of a private container: "storageKey": "?", "storageKeyType": "SharedAccessKey", "storageUri": "[variables('bacpacURL')]" 来源: https://stackoverflow.com

How to restrict Resources count in GET request in AzureRM

三世轮回 提交于 2019-12-11 09:24:26
问题 How to filter the resources count in GET Request in AzureRM ? For an example in List Virtual Machines in an subscription . We get all the Vm's running in an account . But I need to get 10 VM's alone in ascending or any sorting order . Is there any filter available like that ? 回答1: If the sorting order does not matter for you, you can filter the resource count for the top 10 VMs in the GET request below: I've tried the requests below and tweak resource count for filtering and they all worked

Hoe to validate ARM template by passing credentials

℡╲_俬逩灬. 提交于 2019-12-11 08:12:58
问题 My ARM template is running fine. I need to authenticate my ARM template by passing credentials. When I have gone through logs I can see below entries [debug]00000-000000-00000-00000-000000000 auth param serviceprincipalid = ******** [debug]00000-000000-00000-00000-000000000 auth param serviceprincipalkey = ******** What is this Service Principal Id and Service Principal Key? I am not passing these values in ARM template. I am trying to figure out where these values are fetched and what is

Azure resourceManager

自古美人都是妖i 提交于 2019-12-11 07:49:04
问题 I'm trying to scale programmatically an Azure worker role and I can't find the right syntax for the resource name. // Create the autoscale client. AutoscaleClient autoscaleClient = new AutoscaleClient(new CertificateCloudCredentials(subscriptionId, cert)); AutoscaleSettingGetResponse get =autoscaleClient.Settings.Get(AutoscaleResourceIdBuilder.BuildCloudServiceResourceId("WRK-GROUP-NE01","CIW.GROUPS",true) ); AutoscaleSetting setting = get.Setting; It returns : ResourceNotFound: The resource

How can I divide an existing template into linked Templates

一个人想着一个人 提交于 2019-12-11 07:32:20
问题 Auto generated arm templates aren't meant to be production ready, they need refinement. that is expected. How can a Devops staff divide auto generated ARM templates into Linked templates? References Linked Templates https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-group-linked-templates Azure ARM template deployment https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-group-overview#template-deployment 回答1: How can a Devops staff divide auto generated

ARM - Add multiple VM to Recovery Services Vault (copyIndex)

扶醉桌前 提交于 2019-12-11 06:58:43
问题 I'm trying to use the Recovery Services where I can automatically add a VM to Azure Backup via ARM template. I have successfully done this on a single machine deploy, but I'm trying to import it for when multiple VMs are deployed. Here is where I had help from: https://www.francoisdelport.com/2017/03/automating-azure-vm-backups-using-arm-templates/ and Azure ARM JSON template - Add VM to Recovery Services Vault in different Resource Group Here is a snippet from a single deploy I had working {

Mechanism to upload ARM template into storage

主宰稳场 提交于 2019-12-11 06:56:30
问题 I want to use linked templates in my ARM deployment model. Every article I've read mentions that the linked template needs to be in an accessible location (such as blob storage). This works OK if I manually upload the files to storage but I'm looking for a mechanism to upload a template to Storage as part of the build or Deployment process. I'd hoped to use the Artifact Storage Account option but it is unavailable when deploying infrastructure only. Is there a built-in method to achieve this