Module 3 - Configure Resources with ARM templates Flashcards

1
Q

ARM templates

A

it is based on the JSON format. Key and value pairs
Infrastructure as a code

JSON files that define the resources you want to deploy.

If the resource already exists and no change is detected in the properties, no action is taken. If the resource already exists and a property has changed, the resource is updated. If the resource doesn’t exist, it’s created.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

ARM templates advantages

A
  1. Improves consistency and promotes reuse
  2. Reduce manual , error prne , and rep
    3.
    4.
    5.
    6.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

ARM templates Schema

A

Defines all the resources in a deployment

  1. Written in JSON
  2. A collection of key - value pairs
  3. Each key is a string
  4. the string value can be a , a string , a number , Boolean expression , list of values , an object( Which is a collection of other key-value pairs)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

JSON template parameters

A

In the parameter section is where you specify which values you can input when deploying the resources.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Azure Bicept files

A

Is a domain specific language that use declarative syntax to deploy azure resources.

Simpler syntax for writing templates. You can reference parameters and variables without using complicated functions.

Modules - you can break down complex deployments into smaller files and refence them in a main template.

Automatically detects dependencies between resources.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Azure Bicep comparison to Azure arm template.

A

Example of deploying an azure storage account:

ARM template: JSON
{
“$schema”: “https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#”,
“contentVersion”: “1.0.0.0”,
“resources”: [
{
“type”: “Microsoft.Storage/storageAccounts”,
“apiVersion”: “2019-06-01”,
“name”: “mystorageaccount”,
“location”: “East US”,
“sku”: {
“name”: “Standard_LRS”
},
“kind”: “StorageV2”
}
]
}

Bicep: Yaml

param storageAccountName string = ‘mystorageaccount’

resource storageAccount ‘Microsoft.Storage/storageAccounts@2019-06-01’ = {
name: storageAccountName
location: ‘East US’
sku: {
name: ‘Standard_LRS’
}
kind: ‘StorageV2’
}

How well did you know this?
1
Not at all
2
3
4
5
Perfectly