7 hours 58 minutes
Welcome back. In this episode, we're gonna talk about azure resource manager or armed templates.
Our objectives include talking about some azure resource manager concepts and then going into azure resource manager templates.
Before we talk about templates, let's discuss what the azure resource manager is. Overall, this is the employment and management service for azure,
meaning. This is a part of the azure service responsible for deploying and building. The resource is we've been working with whether you use the portal Power Shell seal I or arrest a P I. The Azure Resource Manager service is responsible for receiving the request and handling the output.
The service will authenticate and authorize the request before taking action to build the virtual machine, create a storage account or create a network peering. Because each of these creation methods always run through the AP, I the resource will be consistently deployed, and the results will always be the same.
Now that we know what the azure resource manager is, let's talk about templates. Templates are used to define the resource is being deployed inside of azure.
Now, in the screen shot here, we have an example of what an arm template looks like. And in fact, this is from two different files.
Screen show on the left is from a parameters file where you can define properties of the resource year trying to ploy,
for example, here, the location we have is East us, which is one of our Asher regions.
And here you can see we're gonna be deploying a storage account. So we have to give the name and I have my storage account. 922838
We're also using the standard LRS, which is one of our replication options, using a storage V to account for putting them cool accessed here. And we're saying we're only supporting http as traffic only
on the right hand side is the actual arm template deployment file. Here we take those parameters and use them to define the resource we went to deploy again. It's a storage account and we're inputting those parameters and as the name,
the location and some of the properties for the store to count.
So you can see here. We're just defining how we want the storage account to be made. We don't have to worry about riding out logic to actually deploy it. This is the responsibility of the azure resource Manager service itself. It will take these properties and just go create it. Based on what we have declared in this arm template,
let's jump back out to the azure portal. I'll show you where you can
used these armed templates when you're deploying a resource or you can download them after you have finished creating the resource itself.
Here we are back in our azure portal, and I've already to pull it a storage account. Let's go take a look at its properties.
And with just about any resource inside of azure. If you look under the settings and then export template, we're gonna be able to view
the arm template for the resource that we created.
He collapsed this blade here
and here. You can see exactly what we saw on our screen shot. This is the arm template defining the resource that we already have deployed.
And what's great is you can download this template and reuse it as many times as you want.
Here we have the arm template downloaded an unzipped, and you can see a couple of different files in here. The two I'm going to focus on are the parameters dot Jason and template dot Jason.
I'm gonna open these up inside a visual studio code,
and it's the exact same thing we see inside of the Azure portal.
Opening this up in visual studio code or any other Jason editor is gonna allow us to customize the deployment of our azure resource is
you can also take this same template dot Jason and use it to deploy another resource
back in the azure portal. Let's go click on Create a resource
and you'll want to search for template deployment.
Next, we'll want to build her own template in the editor,
and we're gonna click on load file
and select that template dot Jason, we just download it for other storage account,
click on Safe,
and this is gonna open up what looks very similar to when we go and create our azure resource is instead, a lot of the options are already missing. We do still need to select a resource group. So I'm gonna select my arm demo,
and we do need to give the storage account of name now. Since this storage account is already created, it's not unique. So I'm just gonna add a couple of numbers to the end of it.
Since you are gonna be purchasing an azure resource, you do need to agree to the terms and conditions and then click on purchase.
Let's go back and check out our storage accounts.
Let's click on Refresh, and our new storage account should be here.
And what's great is this is an exact copy of the storage account right above it, except it has a different name is going to have the same type of storage, the same access to your in the same location, so you can see where this becomes really powerful. If you have a resource created that you want to duplicate multiple times,
you don't need to sit there and click through the portal and do it over and over and over.
You could just export the arm template, create a resource and import that template again to create the resource again?
Well, not necessarily important for the easy 300 Sam. I do want to point out that Microsoft makes available several azure quick start templates. Thes air templates created from the community that deployed different Resource is inside of Azure,
for example, joining existing Windows VM to an 80 domain or just deploying a simple Windows BM. Let's go check this one out.
This page. Display some of the information about how the template works. Let's go check it out on Get Hub.
And here you can see this has the same files that we just saw when we downloaded for a storage account.
There's an azure deploy that Jason File and the Parameters file,
and you can very easily just click on. Deploy the azure toe, deploy this arm template inside of your environment. You can use thes quick start templates as a good way to learn about, aren't templates yourself and see how other people have built them, as well as take other people's work and be able to use it to deploy. Resource is inside of your azure tenant.
If you're learning Maur or just deploying them in your production environment
that does it for a demo. Let's jump back to the slides and wrap this up.
That does it for this episode. But before we move on, I do have a post assessment question for you. I wanted to ask, What format are armed tipple? It's written in.
Coming up in the next episode, we're gonna start talking a little bit more about identity and Azure active directory with our introduction to Azure Active Directory.
See you in the next episode.