Azure Availability Set-ARM-Template - Ready-to-Deploy Reusable Solution

Azure Availability Set-ARM-Template - Ready-to-Deploy Reusable Solution

$25.00
Sale price  $25.00 Regular price 
Skip to product information
Azure Availability Set-ARM-Template - Ready-to-Deploy Reusable Solution

Azure Availability Set-ARM-Template - Ready-to-Deploy Reusable Solution

$25.00
Sale price  $25.00 Regular price 

Overview
This ARM template deploys a **Highly Available Virtual Machine Infrastructure** in Microsoft Azure using an **Availability Set**.

The Deployment Includes:
* One Availability Set
* Two Virtual Machines (VMs)
* Two Network Interfaces (NICs)
* One Virtual Network (VNet)
* One Subnet
This design ensures **Fault Tolerance and Update Resiliency** by distributing VMs across Fault Domains and Update Domains within a Single Azure Region (Availability Sets are Region-Scoped)

Availability Set Architecture Design
The Availability Set ensures:
*Fault Domain isolation (Protection against Hardware Failure)
*Update Domain Distribution (Protection During Maintenance Events)

Virtual Machines
* Two VMs are Deployed
* Both are placed in the same Availability Set
* Each VM is Attached to its own NIC

Networking
* A dedicated VNet is deployed
* A Subnet is created for VM placement
* Each VM receives a dynamically assigned private IP

Resources Deployed
The template creates the following Azure Resources:
1. Microsoft.Network/virtualNetworks
2. Microsoft.Compute/availabilitySets
3. Microsoft.Network/networkInterfaces (2 Instances)
4. Microsoft.Compute/virtualMachines (2 Instances)

Key Features
* Fully Parameterized Deployment
* Deterministic Resource creation order
* Managed Disks with configurable Storage Type
* Safe VM naming logic (Prevents Substring Errors)
* Automatic cleanup behavior for NICs (deleteOption enabled)
* Consistent tagging across all resources
* Designed for Test, Development, and Production use

Prerequisites
Before using this Template, ensure:
* Azure Subscription is Active
* Resource Group exists (example: <RG-NameHere>)
* Azure CLI or Cloud Shell is available
* Required permissions (Contributor or higher)

Files Included
template.json
Defines the infrastructure resources
parameters.json
Provides environment-specific values
deploy.ps1
Automates validation, simulation, and optional deployment

Deployment Process

Step 1 – Upload Files to Cloud Shell
Upload:
template.json
parameters.json
deploy.ps1

Step 2 – Validate Template
Run:
az deployment group validate 
--resource-group <RG-NameHere> 
--template-file template.json 
--parameters parameters.json

Step 3 – Run WHAT-IF (Simulation Only)
Run:
az deployment group what-if 
--resource-group <RG-NameHere> 
--template-file template.json 
--parameters parameters.json

Step 4 – Optional Deployment
Run only if actual deployment is required:
az deployment group create 
--resource-group RG-ARM-TEMPLATES 
--template-file template.json 
--parameters parameters.json

Testing and Validation
Testing Performed
The following validation steps were successfully completed:
1. Template validation without parameters
2. Template validation with inline parameters
3. Template validation using parameters.json
4. Azure WHAT-IF simulation

WHAT-IF Results
Expected and confirmed output:
Resource changes: 6 to create

Resources Validated
* Virtual Network
* Availability Set
* Network Interfaces (2)
* Virtual Machines (2)

Validation Outcomes
* No syntax errors
* No ARM Function Failures (Substring Logic Corrected)
* No Dependency Conflicts
* All parameters resolved successfully
* Azure accepted all configurations

Important Notes
* WHAT-IF testing does NOT deploy resources
* No cost is incurred during validation
* VM deployment will incur a cost if executed
* Passwords in parameters.json are for testing only
* Use secure methods (Key Vault or CLI Prompt) in Production

Best Practices
* Keep VM count aligned with Fault Domain Strategy
* Use Availability Sets for smaller Workloads
* Use Virtual Machine Scale Sets for Large-Scale Deployments
* Separate Environments using Different VNets
* Apply consistent tagging for Governance
* Use Managed Disks for Performance and Reliability

Future Enhancements
This template can be extended to include:
* Load Balancer (for VM traffic distribution)
* Network Security Groups (NSGs)
* Azure Backup integration
* Boot diagnostics
* Custom script extensions
* Domain join automation
* Monitoring with Azure Monitor

Summary
This Availability Set ARM template is:
* Fully validated and tested
* Deterministic and reliable
* Enterprise-ready
* Safe to deploy
* Designed for high availability

It provides a foundational pattern for deploying resilient virtual machines in Azure using Infrastructure as Code.

Support
For questions or custom template requests, please contact:

ITCloudAcademy Support Team
Email: 
support@ITCloudAcademy.net
Email: 
info@ITCloudAcademy.net
Website: 
http://www.itcloudacademy.net

Support Hours:
Monday to Friday
9:00 AM to 6:00 PM MST

Need a custom Azure ARM template? Visit our Azure Custom ARM Templates page for details and services.

You may also like