Archives For Resource Group


Azure PowerShell Version 1.0 has great benefits, and also has many breaking changes. Since I wrote about moving my DNS to Azure, things have evolved. This is a post about updating an IPV4 on a Naked Domain type A RecordSet.

Most of breaking changes are minor. If your script leveraged Azure Resource Manager (ARM), start by replacing ‘-Azure‘ with ‘-AzureRm‘. This change was made because the Switch-AzureMode CmdLet was removed. Continue Reading…


Oops . . . did I delete that VM?

Accidents happen. Resource Locks help prevent them.

The Resource Lock level is applied at the resource group or resource scope. These can be set by the administrators can be set to CanNotDelete.

Using a modified version of the ARM Template from a post on creating a CentOS Virtual Machine, let’s provision a VM that is protected it from accidental deletion. The best thing about creating locks in ARM Templates, is that it centralizes the configuration. It makes it easier to maintain and simplifies our workflow.

As a best practice, we should consider creating Resource Locks for mission critical resources in our Azure Resource Manager (ARM) Templates.

Continue Reading…


While I was playing around with the Azure Resource Manager Copy Operation, I started thinking about what I could do with it. The first wild idea that popped into my head was, to use it to deploy multi-geo environments from a single ARM Template.

Alright, some of you might think that it’s not such great idea, and I can appreciate that. But I’m just too curious, so let’s give this a chance. Continue Reading…


Deploying 20 CentOS VMs in 4 Minutes!

I recently started to toy around with scenarios that required me to deploy multiple duplicates of the same CentOS Virtual Machine configuration. Working on this scenario got me curious. So I decided to build a template that would allow me to deploy 20 CentOS Virtual Machines each with one 1TB data disk and one public IP addresses.

To my surprise, deploying these 20 Standard A1 CentOS Virtual Machines on Microsoft Azure took 4 minutes!

Building the ARM Template

Let’s start by taking a CentOS ARM Template from a previous post. It will be our starting point for this exercise. Now, let’s removed the extra data disk and removed the Custom Script for Linux Virtual Machine Extension.

To duplicate a resource, we must use the copy operation. It enables us to use an index number or to iterate through an array of values that can be used when deploying a resource.

"copy": {
          "name": "nodeCopy",
          "count": "[parameters('vmCount')]"
}

In this specific scenario, we want all our Virtual Machines to belong to the same Virtual Network and Subnet. Therefore, we need to duplicate each Virtual Machine, their Network Interface Cards (NIC) and their Public IP Addresses.

The following template, demonstrates the use of copyIndex() and concat(), to generate predictable identifiers for each copy. Continue Reading…


Lock it Down!

Accidents happen. Resource Locks help prevent them.

The Resource Lock level is applied at the resource group or resource scope. These can be set by the administrators and current values include CanNotDelete and ReadOnly.

Using a modified version of the ARM Template from a post on creating a CentOS Virtual Machine, let’s provision a VM and protect it from accidental deletion.

As a best practice, we should consider implementing Resource Locks for mission critical resources. Continue Reading…