Azure ARM Templates provides the ability to deploy azure resource infrastructure in a repeatable, declarative and repeatable state. It is infrastructure-as-code.
For those getting started and wondering what they need to build your tool belt, I will share what my tool belt and development process look like.
My Software and tools
My operating system is Windows 10
Visual Studio Code (VS Code)
Lightweight but powerful source code editor. Free.
I prefer this tool as it is very light weight and very popular in the general developer community and not just with Microsoft. I prefer it for its plugin extensions. Alternatives are any code editor you choose and including the latest version Visual Studio for more rich capabilities.
VS Code Extension: Azure Resource Manager Tools
Provides language support for Azure Resource Manager deployment templates and template language expressions.
My favorite features:
- Syntax highlighting & Intellisense
Intellisense of additional properties:
- ARM template snippets
Insert an arm template snippet such as Key Vault to help get started.
As late 2019, there is inline commenting support through this extension.
VS Code Extension: Arm Template Viewer
Displays a graphical preview of Azure Resource Manager (ARM) templates.
I use this when I am starting to use a complicated azure QuickStart arm template to get familiar with the azure resources and how they relate to one another.
Here is a visual of ARM template of an azure function
VS Code Extension: PowerShell
Provides rich PowerShell language support.
Deploying and testing ARM templates using PowerShell is one of the options I regularly use. This is helpful to get the support in VS code vs PowerShell ISE.
VS Code Extension: Azure Account
Provides a single Azure sign-in and subscription filtering experience for all other Azure extensions. It makes Azure’s Cloud Shell service available in VS Code’s integrated terminal.
Git for windows
Local software configuration management (SCM) tool. It is distributed version control system. And you can have a local repository to manage your source control files.
This is a fairly standard tool among IT professionals
A git repository hosting service for public and private scenarios. It supports versioning, branching and collaboration with other developers.
I used this to share my personal demo arm template code and scripts to the public. One example can be found at https://github.com/RoyKimYYZ/azuredeploy-functionapp-sql-keyvault. I also integrate with this CI/CD pipelines such as Azure DevOps Pipelines.
This is not required for simple arm template deployment for your organization.
VS Code Extension: Git Automator
Add and commit all or current file(s) in one shortcut.
Smart auto-prefill for your commit messages.
Push all the local commits on the current branch in one shortcut.
This helps me to just streamline an activity I would do many times in an easy step.
Azure Repos is a set of version control tools that you can use to manage your code. There are two types which are Git and Team Foundation Version Control (TFVC).
I am personally moving towards Git as the standard. I would use Azure Repos in an internal project situation for organizations. The alternative is GitHub private repos.
Pipelines combines continuous integration (CI) and continuous delivery (CD) to constantly and consistently test and build your code and ship it to any target.
I use Pipelines to automate the deployment of ARM Templates targeting specific environments. ARM Templates are not like programmatic code that you compile but files that get sent to Azure Resource Manager for an azure subscription to deploy those defined resource.
These are the collection of software tools I use for DevOps engineering when it comes to ARM template infrastructure as code. Others may have a different approach. If you like to share your approach, feel free to comment in the comments section below.