際際滷

際際滷Share a Scribd company logo
Azure Resource Manager (ARM) Template
A Beginner Guide for Developers
Juv Chan @juvchan juvchan@hotmail.com
Senior Azure Developer
https://www.linkedin.com/in/juv-chan-6104a540
https://github.com/juvchan
http://stackoverflow.com/users/3203213/juvchan
Agenda
 Personal & Professional Background
 ARM Overview
 ARM Template Basics
 ARM Template Usage - Practical Scenarios Demo
 ARM Template Authoring Best Practice
 Known Issues / Limitations
 ARM Template Troubleshooting Tips
 Graduated with a B.ENG. (Computer) Honors degree from the School of Computer
Engineering, Nanyang Technological University some years back
 Study & Work in Singapore for 8 year
 2 years of professional hands-on development experience on the Microsoft Azure platform &
services.
(Azure App Service Web App, Azure Resource Manager Template, Azure PowerShell, Azure SQL Database,
Azure Storage Blob, Azure Storage Table, Azure Traffic Manager, Azure HDInsight, Azure Virtual Machine,
Azure Active Directory etc. )
 Working closely with the Azure Product Development team based in Redmond, Seattle
Background
 3 technical videos on Azure Development & Big Data Analytics featured on Microsofts
Channel 9 website.
 URL: https://channel9.msdn.com/Events/Speakers/juv-chan
 Interactive IIS Log Analysis with Azure HDInsight Spark (Linux)
 Azure Resource Management (ARM) .NET SDK - A Hands-on Beginner Guide
 Azure Web App Management .NET SDK - A Hands-on Guide
Technical Videos Featured on CH9
Azure Resource Manager (ARM) Overview
 Application depend on Infrastructure resources,
e.g. Virtual Machine, Web Server, Database, Storage, Virtual Network etc.
 Traditionally, these resources are viewed as separate, independent entities
E.g. Affinity Group in Azure Service Management (Classic)
 Azure Resource Manager (ARM) Key Concepts:
 Resource Group
 Resource Providers
 Template Deployment
 Tags
 Access Control
 Backbone of Azure Infrastructure As A Service (IaaS)
Azure Resource Manager (ARM) Overview
 Resource Group
Container for a set of resources for an application
 Resource Provider
Service Provider that supplies the resources that can be deployed and managed
through ARM
E.g. Microsoft.Web, Microsoft.Storage, Microsoft.Compute, Microsoft.Network
 Template Deployment
ARM Template (JSON format) defines the infrastructure for your app, how to
configure the infrastructure, and how to publish your app code to that infrastructure
Azure Resource Manager (ARM) Overview
 Tags
Tagging feature enables you to categorize resources based on requirements
 Access Control
Using Role-Based Access Control (RBAC) to control access to resources
Roles: Owner, Reader, Contributor
 REST APIs
Relying on REST APIs to perform create, read, update, delete (CRUD) operations
on resources
ARM Template Basics
 Define the resources that are needed for the application and specify
deployment parameters to input values for different environments.
 Deploys and provisions all of the resources for your application in a single,
coordinated operation
 JSON format
 Infrastructure As Code
 Single Template File (xxx.template.json) +
Single Template Parameter File (xxx.param.json)
ARM Template Basic Format
{
"$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "",
"parameters": { },
"variables": { },
"resources": [ ],
"outputs": { }
}
ARM Template Parameter Basic Format
"parameters": {
"<parameterName>" :
{ "type" : "<type-of-parameter-value>",
"defaultValue": "<optional-default-value-of-parameter>",
"allowedValues": [ "<optional-array-of-allowed-values>" ],
"minValue": <optional-minimum-value-for-int-parameters>,
"maxValue": <optional-maximum-value-for-int-parameters>,
"minLength": <optional-minimum-length-for-string-secureString-array-parameters>,
"maxLength": <optional-maximum-length-for-string-secureString-array-parameters>,
"metadata": { "description": "<optional-description-of-the parameter>" } } }
These parameter values enable you to customize the deployment by providing values
that are tailored for a particular environment (such as dev, test, and production).
You do not have to provide parameters in your template, but without parameters your
template would always deploy the same resources with the same names, locations, and
properties.
Plan Your Template
Before getting started with the template, you should take some time to figure out
what you wish to deploy and how you will use the template.
Key points to consider:
 Which resources types you need to deploy?
 Where those resources will reside?
 Which version of the resource provider API you will use?
 Whether any of the resources must be deployed after other resources?
 Which values you want to pass in during deployment, and which values you
want to define directly in the template?
 Whether you need to return values from the deployment?
Ways to deploy ARM Template
 Azure Portal
 Azure PowerShell
 Azure CLI (Cross-Platform Command Line Interface)
 Azure SDK (.NET, Java, Python, Node.js, Ruby)
ARM Template Usage - Practical Scenarios Demo
ARM Template Authoring Best Practice
 Visual Studio 2015 is the best authoring tool for ARM Template!
 Define Api Versions for different Resource Providers as variables
instead of parameters. Much easier to find and replace.
 Use ARM Template expression function such as trim(), toLower() as a
data cleaning measure to ensure input consistency
 Azure Quick Start Template (GitHub)
 Azure Resource Manager Schema (GitHub) to get the latest Api Version
for the resource providers youre going to use
Known Issues/Limitations
 ARM Template File Size limit = 1 MB
 ARM Template Parameter File Size = 64 KB
 If parameter name value contains . character, the ARM template
deployment will fail in Azure portal (bug)
 E.g. My.Database
 Variables does not support ARM template expression function such as
reference()
ARM Template Troubleshooting Tips
 Azure Resource Explorer
https://resources.azure.com/
 Azure Audit Log
 Azure Quick Start Templates (GitHub)
 Azure Resource Manager Schema (GitHub)
 Stack Overflow / MSDN Forums
 Azure Resource Manager Overview
https://azure.microsoft.com/en-us/documentation/articles/resource-group-overview/
 Azure Quickstart Templates
https://azure.microsoft.com/en-us/documentation/templates/
 Azure Resource Manager providers, regions, API versions and schemas
https://azure.microsoft.com/en-us/documentation/articles/resource-manager-supported-services/
 Azure Resource Manager Schema
https://github.com/Azure/azure-resource-manager-schemas
 Azure Resource Manager REST API Reference
https://msdn.microsoft.com/en-us/library/azure/dn790568.aspx
 Authoring Azure Resource Manager templates
https://azure.microsoft.com/en-us/documentation/articles/resource-group-authoring-templates/
Useful Resources & References
Thank You!

More Related Content

What's hot (6)

Building infrastructure with Azure Resource Manager using PowerShell
Building infrastructure with Azure Resource Manager using PowerShell Building infrastructure with Azure Resource Manager using PowerShell
Building infrastructure with Azure Resource Manager using PowerShell
K.Mohamed Faizal
Microsoft Azure essentials
Microsoft Azure essentialsMicrosoft Azure essentials
Microsoft Azure essentials
Vaibhav Gujral
Automating Your Azure Environment
Automating Your Azure EnvironmentAutomating Your Azure Environment
Automating Your Azure Environment
Michael Collier
Infrastructure as Code for Beginners
Infrastructure as Code for BeginnersInfrastructure as Code for Beginners
Infrastructure as Code for Beginners
David V旦lkel
IaC襦 AWS誤 蟯襴蠍 - 伎 (AUSG) :: AWS Community Day Online 2021
IaC襦 AWS誤 蟯襴蠍 - 伎 (AUSG) :: AWS Community Day Online 2021IaC襦 AWS誤 蟯襴蠍 - 伎 (AUSG) :: AWS Community Day Online 2021
IaC襦 AWS誤 蟯襴蠍 - 伎 (AUSG) :: AWS Community Day Online 2021
AWSKRUG - AWS蟲覈
Programando sua infraestrutura com o AWS CloudFormation
Programando sua infraestrutura com o AWS CloudFormationProgramando sua infraestrutura com o AWS CloudFormation
Programando sua infraestrutura com o AWS CloudFormation
Amazon Web Services LATAM
Building infrastructure with Azure Resource Manager using PowerShell
Building infrastructure with Azure Resource Manager using PowerShell Building infrastructure with Azure Resource Manager using PowerShell
Building infrastructure with Azure Resource Manager using PowerShell
K.Mohamed Faizal
Microsoft Azure essentials
Microsoft Azure essentialsMicrosoft Azure essentials
Microsoft Azure essentials
Vaibhav Gujral
Automating Your Azure Environment
Automating Your Azure EnvironmentAutomating Your Azure Environment
Automating Your Azure Environment
Michael Collier
Infrastructure as Code for Beginners
Infrastructure as Code for BeginnersInfrastructure as Code for Beginners
Infrastructure as Code for Beginners
David V旦lkel
IaC襦 AWS誤 蟯襴蠍 - 伎 (AUSG) :: AWS Community Day Online 2021
IaC襦 AWS誤 蟯襴蠍 - 伎 (AUSG) :: AWS Community Day Online 2021IaC襦 AWS誤 蟯襴蠍 - 伎 (AUSG) :: AWS Community Day Online 2021
IaC襦 AWS誤 蟯襴蠍 - 伎 (AUSG) :: AWS Community Day Online 2021
AWSKRUG - AWS蟲覈
Programando sua infraestrutura com o AWS CloudFormation
Programando sua infraestrutura com o AWS CloudFormationProgramando sua infraestrutura com o AWS CloudFormation
Programando sua infraestrutura com o AWS CloudFormation
Amazon Web Services LATAM

Similar to Azure Resource Manager (ARM) Template - A Beginner Guide for Developers (20)

Azure Resource Manager (ARM) Templates
Azure Resource Manager (ARM) TemplatesAzure Resource Manager (ARM) Templates
Azure Resource Manager (ARM) Templates
WinWire Technologies Inc
Presentation ARM-Terraform DevOps Infrastructure as Code
Presentation ARM-Terraform DevOps Infrastructure as CodePresentation ARM-Terraform DevOps Infrastructure as Code
Presentation ARM-Terraform DevOps Infrastructure as Code
pmukeshpatel31
Deploy and Manage the Infrastructure Using Azure Resource Manager
Deploy and Manage the Infrastructure Using Azure Resource ManagerDeploy and Manage the Infrastructure Using Azure Resource Manager
Deploy and Manage the Infrastructure Using Azure Resource Manager
GlobalLogic Ukraine
Azure ARM Template by Techserverglobal.pptx
Azure ARM Template by Techserverglobal.pptxAzure ARM Template by Techserverglobal.pptx
Azure ARM Template by Techserverglobal.pptx
HarpalGohil4
IaaS with ARM templates for Azure
IaaS with ARM templates for AzureIaaS with ARM templates for Azure
IaaS with ARM templates for Azure
Christoffer Noring
Azure ARMd and Ready
Azure ARMd and ReadyAzure ARMd and Ready
Azure ARMd and Ready
mscug
DevOps in Azure :Azure Resource Manager
DevOps in Azure :Azure Resource ManagerDevOps in Azure :Azure Resource Manager
DevOps in Azure :Azure Resource Manager
Utkarsh Pandey
Supercharged Azure Deployments with ARM Templates
Supercharged Azure Deployments with ARM TemplatesSupercharged Azure Deployments with ARM Templates
Supercharged Azure Deployments with ARM Templates
Cloud Native API-led Integration Meetup
ARM Tempalte Authoring
ARM Tempalte AuthoringARM Tempalte Authoring
ARM Tempalte Authoring
Neil Peterson
Exam 70-533 Module 1-Lesson 6 - Overview of Azure deployment models
Exam 70-533 Module 1-Lesson 6 - Overview of Azure deployment modelsExam 70-533 Module 1-Lesson 6 - Overview of Azure deployment models
Exam 70-533 Module 1-Lesson 6 - Overview of Azure deployment models
Shawn Ismail
O365Con18 - Using ARM Templates to Deploy Solutions on Azure - Kevin Timmermann
O365Con18 - Using ARM Templates to Deploy Solutions on Azure - Kevin TimmermannO365Con18 - Using ARM Templates to Deploy Solutions on Azure - Kevin Timmermann
O365Con18 - Using ARM Templates to Deploy Solutions on Azure - Kevin Timmermann
NCCOMMS
Deploying a website in Azure using ARM templates
Deploying a website in Azure using ARM templatesDeploying a website in Azure using ARM templates
Deploying a website in Azure using ARM templates
Pratik Khasnabis
Manage Azure Cloud with ARM Templates
Manage Azure Cloud with ARM TemplatesManage Azure Cloud with ARM Templates
Manage Azure Cloud with ARM Templates
Manuj Aggarwal
Global Azure Bootcamp 2018 - Azure Resource Manager (ARM)
Global Azure Bootcamp 2018 - Azure Resource Manager (ARM)Global Azure Bootcamp 2018 - Azure Resource Manager (ARM)
Global Azure Bootcamp 2018 - Azure Resource Manager (ARM)
Adin Ermie
Azure ARM Template
Azure ARM TemplateAzure ARM Template
Azure ARM Template
DevOps Indonesia
Azure Templates for Consistent Deployment
Azure Templates for Consistent DeploymentAzure Templates for Consistent Deployment
Azure Templates for Consistent Deployment
Jos辿 Maia
Azure arm templates
Azure arm templatesAzure arm templates
Azure arm templates
sachinkalia15
Azure for SharePoint Developers - Workshop - Part 3: Web Services
Azure for SharePoint Developers - Workshop - Part 3: Web ServicesAzure for SharePoint Developers - Workshop - Part 3: Web Services
Azure for SharePoint Developers - Workshop - Part 3: Web Services
Bob German
06_DP_300T00A_Automate.pptx
06_DP_300T00A_Automate.pptx06_DP_300T00A_Automate.pptx
06_DP_300T00A_Automate.pptx
KareemBullard1
Making production deployments safe and repeatable using declarative infrastru...
Making production deployments safe and repeatable using declarative infrastru...Making production deployments safe and repeatable using declarative infrastru...
Making production deployments safe and repeatable using declarative infrastru...
Microsoft Tech Community
Presentation ARM-Terraform DevOps Infrastructure as Code
Presentation ARM-Terraform DevOps Infrastructure as CodePresentation ARM-Terraform DevOps Infrastructure as Code
Presentation ARM-Terraform DevOps Infrastructure as Code
pmukeshpatel31
Deploy and Manage the Infrastructure Using Azure Resource Manager
Deploy and Manage the Infrastructure Using Azure Resource ManagerDeploy and Manage the Infrastructure Using Azure Resource Manager
Deploy and Manage the Infrastructure Using Azure Resource Manager
GlobalLogic Ukraine
Azure ARM Template by Techserverglobal.pptx
Azure ARM Template by Techserverglobal.pptxAzure ARM Template by Techserverglobal.pptx
Azure ARM Template by Techserverglobal.pptx
HarpalGohil4
IaaS with ARM templates for Azure
IaaS with ARM templates for AzureIaaS with ARM templates for Azure
IaaS with ARM templates for Azure
Christoffer Noring
Azure ARMd and Ready
Azure ARMd and ReadyAzure ARMd and Ready
Azure ARMd and Ready
mscug
DevOps in Azure :Azure Resource Manager
DevOps in Azure :Azure Resource ManagerDevOps in Azure :Azure Resource Manager
DevOps in Azure :Azure Resource Manager
Utkarsh Pandey
ARM Tempalte Authoring
ARM Tempalte AuthoringARM Tempalte Authoring
ARM Tempalte Authoring
Neil Peterson
Exam 70-533 Module 1-Lesson 6 - Overview of Azure deployment models
Exam 70-533 Module 1-Lesson 6 - Overview of Azure deployment modelsExam 70-533 Module 1-Lesson 6 - Overview of Azure deployment models
Exam 70-533 Module 1-Lesson 6 - Overview of Azure deployment models
Shawn Ismail
O365Con18 - Using ARM Templates to Deploy Solutions on Azure - Kevin Timmermann
O365Con18 - Using ARM Templates to Deploy Solutions on Azure - Kevin TimmermannO365Con18 - Using ARM Templates to Deploy Solutions on Azure - Kevin Timmermann
O365Con18 - Using ARM Templates to Deploy Solutions on Azure - Kevin Timmermann
NCCOMMS
Deploying a website in Azure using ARM templates
Deploying a website in Azure using ARM templatesDeploying a website in Azure using ARM templates
Deploying a website in Azure using ARM templates
Pratik Khasnabis
Manage Azure Cloud with ARM Templates
Manage Azure Cloud with ARM TemplatesManage Azure Cloud with ARM Templates
Manage Azure Cloud with ARM Templates
Manuj Aggarwal
Global Azure Bootcamp 2018 - Azure Resource Manager (ARM)
Global Azure Bootcamp 2018 - Azure Resource Manager (ARM)Global Azure Bootcamp 2018 - Azure Resource Manager (ARM)
Global Azure Bootcamp 2018 - Azure Resource Manager (ARM)
Adin Ermie
Azure Templates for Consistent Deployment
Azure Templates for Consistent DeploymentAzure Templates for Consistent Deployment
Azure Templates for Consistent Deployment
Jos辿 Maia
Azure arm templates
Azure arm templatesAzure arm templates
Azure arm templates
sachinkalia15
Azure for SharePoint Developers - Workshop - Part 3: Web Services
Azure for SharePoint Developers - Workshop - Part 3: Web ServicesAzure for SharePoint Developers - Workshop - Part 3: Web Services
Azure for SharePoint Developers - Workshop - Part 3: Web Services
Bob German
06_DP_300T00A_Automate.pptx
06_DP_300T00A_Automate.pptx06_DP_300T00A_Automate.pptx
06_DP_300T00A_Automate.pptx
KareemBullard1
Making production deployments safe and repeatable using declarative infrastru...
Making production deployments safe and repeatable using declarative infrastru...Making production deployments safe and repeatable using declarative infrastru...
Making production deployments safe and repeatable using declarative infrastru...
Microsoft Tech Community
Ad

Recently uploaded (20)

Jira Administration Training Day 1 : Introduction
Jira Administration Training  Day 1 : IntroductionJira Administration Training  Day 1 : Introduction
Jira Administration Training Day 1 : Introduction
Ravi Teja
If You Use Databricks, You Definitely Need FME
If You Use Databricks, You Definitely Need FMEIf You Use Databricks, You Definitely Need FME
If You Use Databricks, You Definitely Need FME
Safe Software
ISOIEC 42005 Revolutionalises AI Impact Assessment.pptx
ISOIEC 42005 Revolutionalises AI Impact Assessment.pptxISOIEC 42005 Revolutionalises AI Impact Assessment.pptx
ISOIEC 42005 Revolutionalises AI Impact Assessment.pptx
AyilurRamnath1
Your startup on AWS - How to architect and maintain a Lean and Mean account
Your startup on AWS - How to architect and maintain a Lean and Mean accountYour startup on AWS - How to architect and maintain a Lean and Mean account
Your startup on AWS - How to architect and maintain a Lean and Mean account
angelo60207
GIS and FME: The Foundation to Improve the Locate Process of Utilities
GIS and FME: The Foundation to Improve the Locate Process of UtilitiesGIS and FME: The Foundation to Improve the Locate Process of Utilities
GIS and FME: The Foundation to Improve the Locate Process of Utilities
Safe Software
Scaling GenAI Inference From Prototype to Production: Real-World Lessons in S...
Scaling GenAI Inference From Prototype to Production: Real-World Lessons in S...Scaling GenAI Inference From Prototype to Production: Real-World Lessons in S...
Scaling GenAI Inference From Prototype to Production: Real-World Lessons in S...
Anish Kumar
How to Detect Outliers in IBM SPSS Statistics.pptx
How to Detect Outliers in IBM SPSS Statistics.pptxHow to Detect Outliers in IBM SPSS Statistics.pptx
How to Detect Outliers in IBM SPSS Statistics.pptx
Version 1 Analytics
Improving Developer Productivity With DORA, SPACE, and DevEx
Improving Developer Productivity With DORA, SPACE, and DevExImproving Developer Productivity With DORA, SPACE, and DevEx
Improving Developer Productivity With DORA, SPACE, and DevEx
Justin Reock
Agentic AI: Beyond the Buzz- LangGraph Studio V2
Agentic AI: Beyond the Buzz- LangGraph Studio V2Agentic AI: Beyond the Buzz- LangGraph Studio V2
Agentic AI: Beyond the Buzz- LangGraph Studio V2
Shashikant Jagtap
Oracle Cloud Infrastructure AI Foundations
Oracle Cloud Infrastructure AI FoundationsOracle Cloud Infrastructure AI Foundations
Oracle Cloud Infrastructure AI Foundations
VICTOR MAESTRE RAMIREZ
DevOps in the Modern Era - Thoughtfully Critical Podcast
DevOps in the Modern Era - Thoughtfully Critical PodcastDevOps in the Modern Era - Thoughtfully Critical Podcast
DevOps in the Modern Era - Thoughtfully Critical Podcast
Chris Wahl
7 Salesforce Data Cloud Best Practices.pdf
7 Salesforce Data Cloud Best Practices.pdf7 Salesforce Data Cloud Best Practices.pdf
7 Salesforce Data Cloud Best Practices.pdf
Minuscule Technologies
How Advanced Environmental Detection Is Revolutionizing Oil & Gas Safety.pdf
How Advanced Environmental Detection Is Revolutionizing Oil & Gas Safety.pdfHow Advanced Environmental Detection Is Revolutionizing Oil & Gas Safety.pdf
How Advanced Environmental Detection Is Revolutionizing Oil & Gas Safety.pdf
Rejig Digital
6th Power Grid Model Meetup - 21 May 2025
6th Power Grid Model Meetup - 21 May 20256th Power Grid Model Meetup - 21 May 2025
6th Power Grid Model Meetup - 21 May 2025
DanBrown980551
vertical-cnc-processing-centers-drillteq-v-200-en.pdf
vertical-cnc-processing-centers-drillteq-v-200-en.pdfvertical-cnc-processing-centers-drillteq-v-200-en.pdf
vertical-cnc-processing-centers-drillteq-v-200-en.pdf
AmirStern2
AI Agents in Logistics and Supply Chain Applications Benefits and Implementation
AI Agents in Logistics and Supply Chain Applications Benefits and ImplementationAI Agents in Logistics and Supply Chain Applications Benefits and Implementation
AI Agents in Logistics and Supply Chain Applications Benefits and Implementation
Christine Shepherd
Boosting MySQL with Vector Search -THE VECTOR SEARCH CONFERENCE 2025 .pdf
Boosting MySQL with Vector Search -THE VECTOR SEARCH CONFERENCE 2025 .pdfBoosting MySQL with Vector Search -THE VECTOR SEARCH CONFERENCE 2025 .pdf
Boosting MySQL with Vector Search -THE VECTOR SEARCH CONFERENCE 2025 .pdf
Alkin Tezuysal
Data Virtualization: Bringing the Power of FME to Any Application
Data Virtualization: Bringing the Power of FME to Any ApplicationData Virtualization: Bringing the Power of FME to Any Application
Data Virtualization: Bringing the Power of FME to Any Application
Safe Software
LSNIF: Locally-Subdivided Neural Intersection Function
LSNIF: Locally-Subdivided Neural Intersection FunctionLSNIF: Locally-Subdivided Neural Intersection Function
LSNIF: Locally-Subdivided Neural Intersection Function
Takahiro Harada
Your startup on AWS - How to architect and maintain a Lean and Mean account J...
Your startup on AWS - How to architect and maintain a Lean and Mean account J...Your startup on AWS - How to architect and maintain a Lean and Mean account J...
Your startup on AWS - How to architect and maintain a Lean and Mean account J...
angelo60207
Jira Administration Training Day 1 : Introduction
Jira Administration Training  Day 1 : IntroductionJira Administration Training  Day 1 : Introduction
Jira Administration Training Day 1 : Introduction
Ravi Teja
If You Use Databricks, You Definitely Need FME
If You Use Databricks, You Definitely Need FMEIf You Use Databricks, You Definitely Need FME
If You Use Databricks, You Definitely Need FME
Safe Software
ISOIEC 42005 Revolutionalises AI Impact Assessment.pptx
ISOIEC 42005 Revolutionalises AI Impact Assessment.pptxISOIEC 42005 Revolutionalises AI Impact Assessment.pptx
ISOIEC 42005 Revolutionalises AI Impact Assessment.pptx
AyilurRamnath1
Your startup on AWS - How to architect and maintain a Lean and Mean account
Your startup on AWS - How to architect and maintain a Lean and Mean accountYour startup on AWS - How to architect and maintain a Lean and Mean account
Your startup on AWS - How to architect and maintain a Lean and Mean account
angelo60207
GIS and FME: The Foundation to Improve the Locate Process of Utilities
GIS and FME: The Foundation to Improve the Locate Process of UtilitiesGIS and FME: The Foundation to Improve the Locate Process of Utilities
GIS and FME: The Foundation to Improve the Locate Process of Utilities
Safe Software
Scaling GenAI Inference From Prototype to Production: Real-World Lessons in S...
Scaling GenAI Inference From Prototype to Production: Real-World Lessons in S...Scaling GenAI Inference From Prototype to Production: Real-World Lessons in S...
Scaling GenAI Inference From Prototype to Production: Real-World Lessons in S...
Anish Kumar
How to Detect Outliers in IBM SPSS Statistics.pptx
How to Detect Outliers in IBM SPSS Statistics.pptxHow to Detect Outliers in IBM SPSS Statistics.pptx
How to Detect Outliers in IBM SPSS Statistics.pptx
Version 1 Analytics
Improving Developer Productivity With DORA, SPACE, and DevEx
Improving Developer Productivity With DORA, SPACE, and DevExImproving Developer Productivity With DORA, SPACE, and DevEx
Improving Developer Productivity With DORA, SPACE, and DevEx
Justin Reock
Agentic AI: Beyond the Buzz- LangGraph Studio V2
Agentic AI: Beyond the Buzz- LangGraph Studio V2Agentic AI: Beyond the Buzz- LangGraph Studio V2
Agentic AI: Beyond the Buzz- LangGraph Studio V2
Shashikant Jagtap
Oracle Cloud Infrastructure AI Foundations
Oracle Cloud Infrastructure AI FoundationsOracle Cloud Infrastructure AI Foundations
Oracle Cloud Infrastructure AI Foundations
VICTOR MAESTRE RAMIREZ
DevOps in the Modern Era - Thoughtfully Critical Podcast
DevOps in the Modern Era - Thoughtfully Critical PodcastDevOps in the Modern Era - Thoughtfully Critical Podcast
DevOps in the Modern Era - Thoughtfully Critical Podcast
Chris Wahl
7 Salesforce Data Cloud Best Practices.pdf
7 Salesforce Data Cloud Best Practices.pdf7 Salesforce Data Cloud Best Practices.pdf
7 Salesforce Data Cloud Best Practices.pdf
Minuscule Technologies
How Advanced Environmental Detection Is Revolutionizing Oil & Gas Safety.pdf
How Advanced Environmental Detection Is Revolutionizing Oil & Gas Safety.pdfHow Advanced Environmental Detection Is Revolutionizing Oil & Gas Safety.pdf
How Advanced Environmental Detection Is Revolutionizing Oil & Gas Safety.pdf
Rejig Digital
6th Power Grid Model Meetup - 21 May 2025
6th Power Grid Model Meetup - 21 May 20256th Power Grid Model Meetup - 21 May 2025
6th Power Grid Model Meetup - 21 May 2025
DanBrown980551
vertical-cnc-processing-centers-drillteq-v-200-en.pdf
vertical-cnc-processing-centers-drillteq-v-200-en.pdfvertical-cnc-processing-centers-drillteq-v-200-en.pdf
vertical-cnc-processing-centers-drillteq-v-200-en.pdf
AmirStern2
AI Agents in Logistics and Supply Chain Applications Benefits and Implementation
AI Agents in Logistics and Supply Chain Applications Benefits and ImplementationAI Agents in Logistics and Supply Chain Applications Benefits and Implementation
AI Agents in Logistics and Supply Chain Applications Benefits and Implementation
Christine Shepherd
Boosting MySQL with Vector Search -THE VECTOR SEARCH CONFERENCE 2025 .pdf
Boosting MySQL with Vector Search -THE VECTOR SEARCH CONFERENCE 2025 .pdfBoosting MySQL with Vector Search -THE VECTOR SEARCH CONFERENCE 2025 .pdf
Boosting MySQL with Vector Search -THE VECTOR SEARCH CONFERENCE 2025 .pdf
Alkin Tezuysal
Data Virtualization: Bringing the Power of FME to Any Application
Data Virtualization: Bringing the Power of FME to Any ApplicationData Virtualization: Bringing the Power of FME to Any Application
Data Virtualization: Bringing the Power of FME to Any Application
Safe Software
LSNIF: Locally-Subdivided Neural Intersection Function
LSNIF: Locally-Subdivided Neural Intersection FunctionLSNIF: Locally-Subdivided Neural Intersection Function
LSNIF: Locally-Subdivided Neural Intersection Function
Takahiro Harada
Your startup on AWS - How to architect and maintain a Lean and Mean account J...
Your startup on AWS - How to architect and maintain a Lean and Mean account J...Your startup on AWS - How to architect and maintain a Lean and Mean account J...
Your startup on AWS - How to architect and maintain a Lean and Mean account J...
angelo60207
Ad

Azure Resource Manager (ARM) Template - A Beginner Guide for Developers

  • 1. Azure Resource Manager (ARM) Template A Beginner Guide for Developers Juv Chan @juvchan juvchan@hotmail.com Senior Azure Developer https://www.linkedin.com/in/juv-chan-6104a540 https://github.com/juvchan http://stackoverflow.com/users/3203213/juvchan
  • 2. Agenda Personal & Professional Background ARM Overview ARM Template Basics ARM Template Usage - Practical Scenarios Demo ARM Template Authoring Best Practice Known Issues / Limitations ARM Template Troubleshooting Tips
  • 3. Graduated with a B.ENG. (Computer) Honors degree from the School of Computer Engineering, Nanyang Technological University some years back Study & Work in Singapore for 8 year 2 years of professional hands-on development experience on the Microsoft Azure platform & services. (Azure App Service Web App, Azure Resource Manager Template, Azure PowerShell, Azure SQL Database, Azure Storage Blob, Azure Storage Table, Azure Traffic Manager, Azure HDInsight, Azure Virtual Machine, Azure Active Directory etc. ) Working closely with the Azure Product Development team based in Redmond, Seattle Background
  • 4. 3 technical videos on Azure Development & Big Data Analytics featured on Microsofts Channel 9 website. URL: https://channel9.msdn.com/Events/Speakers/juv-chan Interactive IIS Log Analysis with Azure HDInsight Spark (Linux) Azure Resource Management (ARM) .NET SDK - A Hands-on Beginner Guide Azure Web App Management .NET SDK - A Hands-on Guide Technical Videos Featured on CH9
  • 5. Azure Resource Manager (ARM) Overview Application depend on Infrastructure resources, e.g. Virtual Machine, Web Server, Database, Storage, Virtual Network etc. Traditionally, these resources are viewed as separate, independent entities E.g. Affinity Group in Azure Service Management (Classic) Azure Resource Manager (ARM) Key Concepts: Resource Group Resource Providers Template Deployment Tags Access Control Backbone of Azure Infrastructure As A Service (IaaS)
  • 6. Azure Resource Manager (ARM) Overview Resource Group Container for a set of resources for an application Resource Provider Service Provider that supplies the resources that can be deployed and managed through ARM E.g. Microsoft.Web, Microsoft.Storage, Microsoft.Compute, Microsoft.Network Template Deployment ARM Template (JSON format) defines the infrastructure for your app, how to configure the infrastructure, and how to publish your app code to that infrastructure
  • 7. Azure Resource Manager (ARM) Overview Tags Tagging feature enables you to categorize resources based on requirements Access Control Using Role-Based Access Control (RBAC) to control access to resources Roles: Owner, Reader, Contributor REST APIs Relying on REST APIs to perform create, read, update, delete (CRUD) operations on resources
  • 8. ARM Template Basics Define the resources that are needed for the application and specify deployment parameters to input values for different environments. Deploys and provisions all of the resources for your application in a single, coordinated operation JSON format Infrastructure As Code Single Template File (xxx.template.json) + Single Template Parameter File (xxx.param.json)
  • 9. ARM Template Basic Format { "$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#", "contentVersion": "", "parameters": { }, "variables": { }, "resources": [ ], "outputs": { } }
  • 10. ARM Template Parameter Basic Format "parameters": { "<parameterName>" : { "type" : "<type-of-parameter-value>", "defaultValue": "<optional-default-value-of-parameter>", "allowedValues": [ "<optional-array-of-allowed-values>" ], "minValue": <optional-minimum-value-for-int-parameters>, "maxValue": <optional-maximum-value-for-int-parameters>, "minLength": <optional-minimum-length-for-string-secureString-array-parameters>, "maxLength": <optional-maximum-length-for-string-secureString-array-parameters>, "metadata": { "description": "<optional-description-of-the parameter>" } } } These parameter values enable you to customize the deployment by providing values that are tailored for a particular environment (such as dev, test, and production). You do not have to provide parameters in your template, but without parameters your template would always deploy the same resources with the same names, locations, and properties.
  • 11. Plan Your Template Before getting started with the template, you should take some time to figure out what you wish to deploy and how you will use the template. Key points to consider: Which resources types you need to deploy? Where those resources will reside? Which version of the resource provider API you will use? Whether any of the resources must be deployed after other resources? Which values you want to pass in during deployment, and which values you want to define directly in the template? Whether you need to return values from the deployment?
  • 12. Ways to deploy ARM Template Azure Portal Azure PowerShell Azure CLI (Cross-Platform Command Line Interface) Azure SDK (.NET, Java, Python, Node.js, Ruby)
  • 13. ARM Template Usage - Practical Scenarios Demo
  • 14. ARM Template Authoring Best Practice Visual Studio 2015 is the best authoring tool for ARM Template! Define Api Versions for different Resource Providers as variables instead of parameters. Much easier to find and replace. Use ARM Template expression function such as trim(), toLower() as a data cleaning measure to ensure input consistency Azure Quick Start Template (GitHub) Azure Resource Manager Schema (GitHub) to get the latest Api Version for the resource providers youre going to use
  • 15. Known Issues/Limitations ARM Template File Size limit = 1 MB ARM Template Parameter File Size = 64 KB If parameter name value contains . character, the ARM template deployment will fail in Azure portal (bug) E.g. My.Database Variables does not support ARM template expression function such as reference()
  • 16. ARM Template Troubleshooting Tips Azure Resource Explorer https://resources.azure.com/ Azure Audit Log Azure Quick Start Templates (GitHub) Azure Resource Manager Schema (GitHub) Stack Overflow / MSDN Forums
  • 17. Azure Resource Manager Overview https://azure.microsoft.com/en-us/documentation/articles/resource-group-overview/ Azure Quickstart Templates https://azure.microsoft.com/en-us/documentation/templates/ Azure Resource Manager providers, regions, API versions and schemas https://azure.microsoft.com/en-us/documentation/articles/resource-manager-supported-services/ Azure Resource Manager Schema https://github.com/Azure/azure-resource-manager-schemas Azure Resource Manager REST API Reference https://msdn.microsoft.com/en-us/library/azure/dn790568.aspx Authoring Azure Resource Manager templates https://azure.microsoft.com/en-us/documentation/articles/resource-group-authoring-templates/ Useful Resources & References