[CODE] Better to use ARM Templates or something else?!

No Comments on [CODE] Better to use ARM Templates or something else?!

I often see the question if it is better to use ARM Templates, or if people should have a look into things like Terraform, Pulumi or something else.

Today I will try to answer this, with a solid:

IT DEPENDS!

Well, I know you don’t like this answer, but it’s actually the most accurate recommendation, in many cases 🙂

Infrastructure as Code as the right way

Basically it is important that you at least are going into the right direction.No matter, which tool, language, framework you are using. Infrastructure as Code is the future. It makes things more predictable, avoids issues, typos, etc.

Available IaC Tools Languages Frameworks - including ARM Templates

It also can be used by a broad range of poeple in an organization, without long and annoying handovers.

So if you are still clicking through the portals, consider this:

  • somebody accidentally deletes your ResourceGroup with your resources in there –> IaC would be your hero … as you could easily recreate stuff
  • imagine one of your colleagues is the one and only who knows how to spin up a VM in Azure and attach it in the right way … but he is on vacation –> IaC would help a lot here
  • …. we could find much more of those ideas

The idea is to have a description of your target environment in a descriptive language (no matter which one) … this makes things more reliable and helps others to understand how things are done.

Also wen placed into a proper repository, you can see changes, switch between version, etc.

So all in all a big +

Templates for small environments?!

One of the common discussions I see is about if and when it is useful to have things in a template. I often hear things like:

  • we only run a small environment, we do not change much … so no template needed
  • templates are useless as we never build the same thing twice .. so we would need templates for every environment
  • ….

And well, I udnerstand … but I would like to give two real life examples to show what that means:

  • I am not driving that much, and also only short routes … I don’t need a drivers license (I know this will raise a lot of discussion)
  • Excel driven applications are useless … they just are build for one workload (but still we have hundreds of Excel based business apps)

Templates can be a pain … as you have to learn how to deal with them … but you will see, it is not that bad … and you will gain a lot of benefits out of them.

Why ARM is always important!?

TO go into the question if ARM Templates are the right thing to learn … I will give it a clear YES!

Why?! – As Azure itself is working with the Azure Resource Manager Templates in many ways … you will get in contact with them … and then you should know how to handle.

Areas where you will find / or have to use ARM Templates

  • Export of an existing Resource Group
  • View of Deployment history
  • Azure Blueprints (right now only support ARM)
  • Community Resources (there is a lot for ARM out there)
  • Microsoft Docs (besides PowerShell and CLI, you will find ARM Template code)

So no matter what your final decision looks like, you should at least know what ARM Templates are, how to read them and what would be the impact of applying them.

If you want to learn about ARM … follow my LinkedIn Learning course (German):

Azure Resource Mangager

Why are there other IaC Tools?!

There are other tools and languages available for a reason. ARM Templates are very Azure specific. So you cannot deploy them to AWS, or to Google, or even On-Premises (except of AzureStack Hub).

So if you are working in a multi-cloud environment for example it could a good idea to have a look into Terraform … even when not everything you can do with ARM Templates is available there … but Terraform also has some features that are not natively available in ARM.

There are also tools to address existing skills of people. If you want to use ARM Templates you have to understand how to work with JSON. To apply those templates you have to handle with PowerShell, CLI or REST.

If you have a look at tools like Pulumi, they are designed to address the skill of existing developers. As it integrates into existing IDEs, has a language that is similar to real languages. It also supports multi-cloud scenarios.

But for someone who is not into DEV … it is hard to learn…

Conclusion

So overall, there is no right or wrong … there is just a way that works for you! And this is the important one.

You should know about the basics of ARM … so that you are not shocked if you see some ARM Template code once …

But everything else is also a valid decision 🙂

Happy Templating

Dieser Post ist auch verfügbar auf: German

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Back to Top