Day 34 - Hands On with Azure

This commit is contained in:
Michael Cade 2022-02-03 18:17:08 +00:00
parent dc32dcec31
commit 2387b7c03e
50 changed files with 851 additions and 5 deletions

View File

@ -0,0 +1,15 @@
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentParameters.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"vmSize": {
"value": "Standard_D2s_v3"
},
"adminUsername": {
"value": "Student"
},
"adminPassword": {
"value": "Pa55w.rd1234"
}
}
}

View File

@ -0,0 +1,162 @@
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"vmSize": {
"type": "string",
"defaultValue": "Standard_D2s_v3",
"metadata": {
"description": "VM size"
}
},
"vmName": {
"type": "string",
"defaultValue": "90day-vm",
"metadata": {
"description": "VM name Prefix"
}
},
"vmCount": {
"type": "int",
"defaultValue": 2,
"metadata": {
"description": "Number of VMs"
}
},
"adminUsername": {
"type": "string",
"metadata": {
"description": "Admin username"
}
},
"adminPassword": {
"type": "securestring",
"metadata": {
"description": "Admin password"
}
},
"virtualNetworkName": {
"type": "string",
"defaultValue": "90daysofdevops",
"metadata": {
"description": "Virtual network name"
}
}
},
"variables": {
"nic": "90daysofdevops",
"virtualNetworkName": "[parameters('virtualNetworkName')]",
"subnetName": "subnet",
"subnet0Name": "subnet0",
"subnet1Name": "subnet1",
"computeApiVersion": "2018-06-01",
"networkApiVersion": "2018-08-01"
},
"resources": [
{
"name": "[concat(parameters('vmName'),copyIndex())]",
"copy": {
"name": "VMcopy",
"count": "[parameters('vmCount')]"
},
"type": "Microsoft.Compute/virtualMachines",
"apiVersion": "[variables('computeApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Creating VMs",
"dependsOn": [
"[concat(variables('nic'),copyIndex())]"
],
"properties": {
"osProfile": {
"computerName": "[concat(parameters('vmName'),copyIndex())]",
"adminUsername": "[parameters('adminUsername')]",
"adminPassword": "[parameters('adminPassword')]",
"windowsConfiguration": {
"provisionVmAgent": "true"
}
},
"hardwareProfile": {
"vmSize": "[parameters('vmSize')]"
},
"storageProfile": {
"imageReference": {
"publisher": "MicrosoftWindowsServer",
"offer": "WindowsServer",
"sku": "2019-Datacenter",
"version": "latest"
},
"osDisk": {
"createOption": "fromImage"
},
"dataDisks": []
},
"networkProfile": {
"networkInterfaces": [
{
"properties": {
"primary": true
},
"id": "[resourceId('Microsoft.Network/networkInterfaces', concat(variables('nic'),copyIndex()))]"
}
]
}
}
},
{
"type": "Microsoft.Network/virtualNetworks",
"name": "[variables('virtualNetworkName')]",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Virtual Network",
"properties": {
"addressSpace": {
"addressPrefixes": [
"10.40.0.0/22"
]
},
"subnets": [
{
"name": "[variables('subnet0Name')]",
"properties": {
"addressPrefix": "10.40.0.0/24"
}
},
{
"name": "[variables('subnet1Name')]",
"properties": {
"addressPrefix": "10.40.1.0/24"
}
}
]
}
},
{
"name": "[concat(variables('nic'),copyIndex())]",
"copy":{
"name": "nicCopy",
"count": "[parameters('vmCount')]"
},
"type": "Microsoft.Network/networkInterfaces",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Primary NIC",
"dependsOn": [
"[concat('Microsoft.Network/virtualNetworks/', variables('virtualNetworkName'))]"
],
"properties": {
"ipConfigurations": [
{
"name": "ipconfig1",
"properties": {
"subnet": {
"id": "[resourceId('Microsoft.Network/virtualNetworks/subnets', variables('virtualNetworkName'), concat(variables('subnetName'),copyIndex()))]"
},
"privateIPAllocationMethod": "Dynamic"
}
}
]
}
}
],
"outputs": {}
}

View File

@ -0,0 +1,6 @@
$rgName = '90DaysOfDevOps'
New-AzResourceGroupDeployment `
-ResourceGroupName $rgName `
-TemplateFile C:\Users\micha\demo\90DaysOfDevOps\Days\Cloud\01VirtualNetworking\Mod04_90DaysOfDevOps-vms-loop-template.json `
-TemplateParameterFile C:\Users\micha\demo\90DaysOfDevOps\Days\Cloud\01VirtualNetworking\Mod04_90DaysOfDevOps-vms-loop-parameters.json

View File

@ -0,0 +1,15 @@
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentParameters.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"vmSize": {
"value": "Standard_D2s_v3"
},
"adminUsername": {
"value": "Student"
},
"adminPassword": {
"value": "Pa55w.rd1234"
}
}
}

View File

@ -0,0 +1,237 @@
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"vmSize": {
"type": "string",
"defaultValue": "Standard_D2s_v3",
"metadata": {
"description": "VM size"
}
},
"vmName": {
"type": "string",
"defaultValue": "90day-vm",
"metadata": {
"description": "VM name Prefix"
}
},
"vmCount": {
"type": "int",
"defaultValue": 4,
"metadata": {
"description": "Number of VMs"
}
},
"adminUsername": {
"type": "string",
"metadata": {
"description": "Admin username"
}
},
"adminPassword": {
"type": "securestring",
"metadata": {
"description": "Admin password"
}
}
},
"variables": {
"vmExtensionName": "customScriptExtension",
"nic": "90day-vm-nic",
"virtualNetworkNames": "[createArray('90day-vm-vnet01','90day-vm-vnet01','90day-vm-vnet2','90day-vm-vnet3')]",
"virtualNetworkNamestbc": "[createArray('90day-vm-vnet01','90day-vm-vnet2','90day-vm-vnet3')]",
"VNetPrefixes":"[createArray('10.60','10.62','10.63')]",
"nsgNames": "[createArray('90day-vm-nsg01','90day-vm-nsg01','90day-vm-nsg2','90day-vm-nsg3')]",
"nsgNamestbc": "[createArray('90day-vm-nsg01','90day-vm-nsg2','90day-vm-nsg3')]",
"subnetName": "subnet",
"subnetRefs": "[createArray(0,1,0,0)]",
"computeApiVersion": "2018-06-01",
"networkApiVersion": "2018-08-01"
},
"resources": [
{
"name": "[concat(parameters('vmName'),copyIndex())]",
"copy": {
"name": "VMcopy",
"count": "[parameters('vmCount')]"
},
"type": "Microsoft.Compute/virtualMachines",
"apiVersion": "[variables('computeApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Creating VMs",
"dependsOn": [
"[concat(variables('nic'),copyIndex())]"
],
"properties": {
"osProfile": {
"computerName": "[concat(parameters('vmName'),copyIndex())]",
"adminUsername": "[parameters('adminUsername')]",
"adminPassword": "[parameters('adminPassword')]",
"windowsConfiguration": {
"provisionVmAgent": "true"
}
},
"hardwareProfile": {
"vmSize": "[parameters('vmSize')]"
},
"storageProfile": {
"imageReference": {
"publisher": "MicrosoftWindowsServer",
"offer": "WindowsServer",
"sku": "2019-Datacenter",
"version": "latest"
},
"osDisk": {
"createOption": "fromImage"
},
"dataDisks": []
},
"networkProfile": {
"networkInterfaces": [
{
"properties": {
"primary": true
},
"id": "[resourceId('Microsoft.Network/networkInterfaces', concat(variables('nic'),copyIndex()))]"
}
]
}
}
},
{
"type": "Microsoft.Compute/virtualMachines/extensions",
"name": "[concat(concat(parameters('vmName'),copyIndex()), '/', variables('vmExtensionName'))]",
"copy": {
"name": "Extopy",
"count": "[parameters('vmCount')]"
},
"apiVersion": "[variables('computeApiVersion')]",
"location": "[resourceGroup().location]",
"dependsOn": [
"[concat('Microsoft.Compute/virtualMachines/', concat(parameters('vmName'),copyIndex()))]"
],
"properties": {
"publisher": "Microsoft.Compute",
"type": "CustomScriptExtension",
"typeHandlerVersion": "1.7",
"autoUpgradeMinorVersion": true,
"settings": {
"commandToExecute": "powershell.exe Install-WindowsFeature -name Web-Server -IncludeManagementTools && powershell.exe remove-item 'C:\\inetpub\\wwwroot\\iisstart.htm' && powershell.exe Add-Content -Path 'C:\\inetpub\\wwwroot\\iisstart.htm' -Value $('Hello World from ' + $env:computername)"
}
}
},
{
"type": "Microsoft.Network/virtualNetworks",
"name": "[variables('virtualNetworkNamestbc')[copyIndex()]]",
"copy": {
"name": "VnetCopy",
"count": "[length(variables('virtualNetworkNamestbc'))]"
},
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Virtual Network",
"properties": {
"addressSpace": {
"addressPrefixes": [
"[concat(variables('VNetPrefixes')[copyIndex()],'.0.0/22')]"
]
},
"subnets": [
{
"name": "[concat(variables('subnetName'),'0')]",
"properties": {
"addressPrefix": "[concat(variables('VNetPrefixes')[copyIndex()],'.0.0/24')]"
}
}
]
}
},
{ "type": "Microsoft.Network/virtualNetworks/subnets",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Virtual Network Subnet for VNet01",
"name": "90day-vm-vnet01/subnet1",
"properties": {
"addressPrefix": "10.60.1.0/24"
},
"dependsOn": [
"Microsoft.Network/virtualNetworks/90day-vm-vnet01"
]
},
{
"name": "[concat(variables('nic'),copyIndex())]",
"copy":{
"name": "nicCopy",
"count": "[parameters('vmCount')]"
},
"type": "Microsoft.Network/networkInterfaces",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Primary NIC",
"dependsOn": [
"[variables('nsgNames')[copyindex()]]",
"[concat('Microsoft.Network/virtualNetworks/', variables('virtualNetworkNames')[copyIndex()])]"
],
"properties": {
"ipConfigurations": [
{
"name": "ipconfig1",
"properties": {
"subnet": {
"id": "[resourceId('Microsoft.Network/virtualNetworks/subnets', variables('virtualNetworkNames')[copyIndex()], concat(variables('subnetName'),variables('subnetRefs')[copyindex()]))]"
},
"privateIPAllocationMethod": "Dynamic"
}
}
],
"networkSecurityGroup": {
"id": "[resourceId('Microsoft.Network/networkSecurityGroups', variables('nsgNames')[copyIndex()])]"
}
}
},
{
"name": "[variables('nsgNamestbc')[copyIndex()]]",
"copy": {
"name": "nsgCopy",
"count": 3
},
"type": "Microsoft.Network/networkSecurityGroups",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Network Security Group (NSG) for Primary NIC",
"properties": {
"securityRules": [
{
"name": "default-allow-rdp",
"properties": {
"priority": 1000,
"sourceAddressPrefix": "*",
"protocol": "Tcp",
"destinationPortRange": "3389",
"access": "Allow",
"direction": "Inbound",
"sourcePortRange": "*",
"destinationAddressPrefix": "*"
}
},
{
"name": "default-allow-http",
"properties": {
"priority": 1100,
"sourceAddressPrefix": "*",
"protocol": "Tcp",
"destinationPortRange": "80",
"access": "Allow",
"direction": "Inbound",
"sourcePortRange": "*",
"destinationAddressPrefix": "*"
}
}
]
}
}
],
"outputs": {}
}

View File

@ -0,0 +1,21 @@
$rgName = '90DaysOfDevOps'
New-AzResourceGroupDeployment `
-ResourceGroupName $rgName `
-TemplateFile C:\Users\micha\demo\90DaysOfDevOps\Days\Cloud\02TrafficManagement\Mod06_90DaysOfDevOps-vms-loop-template.json `
-TemplateParameterFile C:\Users\micha\demo\90DaysOfDevOps\Days\Cloud\02TrafficManagement\Mod06_90DaysOfDevOps-vms-loop-parameters.json
$location = (Get-AzResourceGroup -ResourceGroupName $rgName).location
$vmNames = (Get-AzVM -ResourceGroupName $rgName).Name
foreach ($vmName in $vmNames) {
Set-AzVMExtension `
-ResourceGroupName $rgName `
-Location $location `
-VMName $vmName `
-Name 'networkWatcherAgent' `
-Publisher 'Microsoft.Azure.NetworkWatcher' `
-Type 'NetworkWatcherAgentWindows' `
-TypeHandlerVersion '1.4'
}

View File

@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2018 Microsoft
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View File

@ -0,0 +1,15 @@
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentParameters.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"vmSize": {
"value": "Standard_D2s_v3"
},
"adminUsername": {
"value": "Student"
},
"adminPassword": {
"value": "Pa55w.rd1234"
}
}
}

View File

@ -0,0 +1,172 @@
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"vmSize": {
"type": "string",
"defaultValue": "Standard_D2s_v3",
"metadata": {
"description": "Virtual machine size"
}
},
"adminUsername": {
"type": "string",
"metadata": {
"description": "Admin username"
}
},
"adminPassword": {
"type": "securestring",
"metadata": {
"description": "Admin password"
}
}
},
"variables": {
"vmName": "90Days-vm0",
"nicName": "90Days-nic0",
"virtualNetworkName": "90Days-vnet0",
"publicIPAddressName": "90Days-pip0",
"nsgName": "90Days-nsg0",
"vnetIpPrefix": "10.70.0.0/22",
"subnetIpPrefix": "10.70.0.0/24",
"subnetName": "subnet0",
"subnetRef": "[resourceId('Microsoft.Network/virtualNetworks/subnets', variables('virtualNetworkName'), variables('subnetName'))]",
"computeApiVersion": "2018-06-01",
"networkApiVersion": "2018-08-01"
},
"resources": [
{
"name": "[variables('vmName')]",
"type": "Microsoft.Compute/virtualMachines",
"apiVersion": "[variables('computeApiVersion')]",
"location": "[resourceGroup().location]",
"dependsOn": [
"[variables('nicName')]"
],
"properties": {
"osProfile": {
"computerName": "[variables('vmName')]",
"adminUsername": "[parameters('adminUsername')]",
"adminPassword": "[parameters('adminPassword')]",
"windowsConfiguration": {
"provisionVmAgent": "true"
}
},
"hardwareProfile": {
"vmSize": "[parameters('vmSize')]"
},
"storageProfile": {
"imageReference": {
"publisher": "MicrosoftWindowsServer",
"offer": "WindowsServer",
"sku": "2019-Datacenter",
"version": "latest"
},
"osDisk": {
"createOption": "fromImage"
},
"dataDisks": []
},
"networkProfile": {
"networkInterfaces": [
{
"properties": {
"primary": true
},
"id": "[resourceId('Microsoft.Network/networkInterfaces', variables('nicName'))]"
}
]
}
}
},
{
"type": "Microsoft.Network/virtualNetworks",
"name": "[variables('virtualNetworkName')]",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Virtual Network",
"properties": {
"addressSpace": {
"addressPrefixes": [
"[variables('vnetIpPrefix')]"
]
},
"subnets": [
{
"name": "[variables('subnetName')]",
"properties": {
"addressPrefix": "[variables('subnetIpPrefix')]"
}
}
]
}
},
{
"name": "[variables('nicName')]",
"type": "Microsoft.Network/networkInterfaces",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Primary NIC",
"dependsOn": [
"[variables('publicIpAddressName')]",
"[variables('nsgName')]",
"[variables('virtualNetworkName')]"
],
"properties": {
"ipConfigurations": [
{
"name": "ipconfig1",
"properties": {
"subnet": {
"id": "[variables('subnetRef')]"
},
"privateIPAllocationMethod": "Dynamic",
"publicIpAddress": {
"id": "[resourceId('Microsoft.Network/publicIpAddresses', variables('publicIpAddressName'))]"
}
}
}
],
"networkSecurityGroup": {
"id": "[resourceId('Microsoft.Network/networkSecurityGroups', variables('nsgName'))]"
}
}
},
{
"name": "[variables('publicIpAddressName')]",
"type": "Microsoft.Network/publicIpAddresses",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Public IP for Primary NIC",
"properties": {
"publicIpAllocationMethod": "Dynamic"
}
},
{
"name": "[variables('nsgName')]",
"type": "Microsoft.Network/networkSecurityGroups",
"apiVersion": "[variables('networkApiVersion')]",
"location": "[resourceGroup().location]",
"comments": "Network Security Group (NSG) for Primary NIC",
"properties": {
"securityRules": [
{
"name": "default-allow-rdp",
"properties": {
"priority": 1000,
"sourceAddressPrefix": "*",
"protocol": "Tcp",
"destinationPortRange": "3389",
"access": "Allow",
"direction": "Inbound",
"sourcePortRange": "*",
"destinationAddressPrefix": "*"
}
}
]
}
}
],
"outputs": {}
}

View File

@ -0,0 +1,7 @@
$rgName = '90DaysOfDevOps'
New-AzResourceGroupDeployment `
-ResourceGroupName $rgName `
-TemplateFile C:\Users\micha\demo\90DaysOfDevOps\Days\Cloud\03Storage\Mod07_90DaysOfDevOps-vm-template.json `
-TemplateParameterFile C:\Users\micha\demo\90DaysOfDevOps\Days\Cloud\03Storage\Mod07_90DaysOfDevOps-vm-parameters.json `
-AsJob

View File

@ -0,0 +1,7 @@
$rgName = '90DaysOfDevOps'
$webapp = Get-AzWebApp -ResourceGroupName $rgName
#The following following will start an infinite loop that sends the HTTP requests to the web app
while ($true) { Invoke-WebRequest -Uri $webapp.DefaultHostName }

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 92 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 77 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 68 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 95 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 405 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 67 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 127 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

View File

@ -4,16 +4,184 @@ The last 6 days have been focused on Microsoft Azure and the public cloud in gen
I mentioned at the very beginning about getting a foundational knowledge of the public cloud and choosing one provider to at least begin with, if you are dancing between different clouds then I believe you can get lost quite easily whereas choosing one you get to understand the fundamentals and when you have those it is quite easy to jump into the other clouds and accelerate your learning. I mentioned at the very beginning about getting a foundational knowledge of the public cloud and choosing one provider to at least begin with, if you are dancing between different clouds then I believe you can get lost quite easily whereas choosing one you get to understand the fundamentals and when you have those it is quite easy to jump into the other clouds and accelerate your learning.
In this final session, I am going to be picking and choosing my hands-on scenarios from this page here which is a reference created by Microsoft and is used for preparations for the [AZ-104 Microsoft Azure Administrator](https://microsoftlearning.github.io/AZ-104-MicrosoftAzureAdministrator/) There are some here such as Containers and Kubernetes that we have not covered in any detail as of yet so I don't want to jump in there just yet. In this final session, I am going to be picking and choosing my hands-on scenarios from this page here which is a reference created by Microsoft and is used for preparations for the [AZ-104 Microsoft Azure Administrator](https://microsoftlearning.github.io/AZ-104-MicrosoftAzureAdministrator/)
There are some here such as Containers and Kubernetes that we have not covered in any detail as of yet so I don't want to jump in there just yet.
In previous posts, we have created most of Modules 1,2 and 3. In previous posts, we have created most of Modules 1,2 and 3.
### Virtual Networking ### Virtual Networking
Following [Module 04](https://microsoftlearning.github.io/AZ-104-MicrosoftAzureAdministrator/Instructions/Labs/LAB_04-Implement_Virtual_Networking.html):
I went through the above and changed a few namings for the purpose of #90DaysOfDevOps. I also instead of using the Cloud Shell went ahead and logged in with my new user created on previous days with the Azure CLI on my Windows machine.
You can do this using the `az login` which will open a browser and let you authenticate to your account.
I have then created a PowerShell script and some references from the module to use to build out some of the tasks below. You can find the associated files in this folder.
(Cloud\01VirtualNetworking)
Please make sure you change the file location in the script to suit your environment.
At this first stage we have no virtual network or virtual machines created in our environment, I only have a cloudshell storage location configured in my resource group.
I first of all run my [PowerShell script](Cloud/01VirtualNetworking/Module4_90DaysOfDevOps.ps1)
![](Images/Day34_Cloud1.png)
- Task 1: Create and configure a virtual network
![](Images/Day34_Cloud2.png)
- Task 2: Deploy virtual machines into the virtual network
![](Images/Day34_Cloud3.png)
- Task 3: Configure private and public IP addresses of Azure VMs
![](Images/Day34_Cloud4.png)
- Task 4: Configure network security groups
![](Images/Day34_Cloud5.png)
![](Images/Day34_Cloud6.png)
- Task 5: Configure Azure DNS for internal name resolution
![](Images/Day34_Cloud7.png)
![](Images/Day34_Cloud8.png)
### Network Traffic Management ### Network Traffic Management
Following [Module 06](https://microsoftlearning.github.io/AZ-104-MicrosoftAzureAdministrator/Instructions/Labs/LAB_06-Implement_Network_Traffic_Management.html):
Next walkthrough, from the last one we have gone into our resource group and deleted our resources, if you had not set up the user account like me to only have access to that one resource group you could follow the module changing the name to `90Days*` this will delete all resources and resource group. This will be my process for each of the following lab.
For this lab I have also created a PowerShell script and some references from the module to use to build out some of the tasks below. You can find the associated files in this folder.
(Cloud\02TrafficManagement)
- Task 1: Provision the lab environment
I first of all run my [PowerShell script](Cloud/02TrafficManagement/Mod06_90DaysOfDevOps.ps1)
![](Images/Day34_Cloud9.png)
- Task 2: Configure the hub and spoke network topology
![](Images/Day34_Cloud10.png)
- Task 3: Test transitivity of virtual network peering
For this my 90DaysOfDevOps group did not have access to the Network Watcher because of permissions, I expect this is because Network Watchers are one of those resources that are not tied to a resource group which is where our RBAC was covered for this user. I added the East US Network Watcher contributer role to the 90DaysOfDevOps group.
![](Images/Day34_Cloud11.png)
![](Images/Day34_Cloud12.png)
![](Images/Day34_Cloud13.png)
^ This is expected, since the two spoke virtual networks are not peered with each other (virtual network peering is not transitive).
- Task 4: Configure routing in the hub and spoke topology
I had another issue here with my account not being able to run the script as my user within the group 90DaysOfDevOps which I am unsure of so I did jump back into my main admin account. The 90DaysOfDevOps group is an owner of everything in the 90DaysOfDevOps Resource Group so would love to understand why I cannot run a command inside the VM?
![](Images/Day34_Cloud14.png)
![](Images/Day34_Cloud15.png)
I then was able to go back into my michael.cade@90DaysOfDevOps.com account and continue this section. Here we are running the same test again but now with the result being reachable.
![](Images/Day34_Cloud16.png)
- Task 5: Implement Azure Load Balancer
![](Images/Day34_Cloud17.png)
![](Images/Day34_Cloud18.png)
- Task 6: Implement Azure Application Gateway
![](Images/Day34_Cloud19.png)
![](Images/Day34_Cloud20.png)
### Azure Storage ### Azure Storage
Following [Module 07](https://microsoftlearning.github.io/AZ-104-MicrosoftAzureAdministrator/Instructions/Labs/LAB_07-Manage_Azure_Storage.html):
### Virtual Machines For this lab I have also created a PowerShell script and some references from the module to use to build out some of the tasks below. You can find the associated files in this folder.
(Cloud\03Storage)
### Serverless (Implement Web Apps) - Task 1: Provision the lab environment
I first of all run my [PowerShell script](Cloud/03Storage/Mod07_90DaysOfDeveOps.ps1)
![](Images/Day34_Cloud21.png)
- Task 2: Create and configure Azure Storage accounts
![](Images/Day34_Cloud22.png)
- Task 3: Manage blob storage
![](Images/Day34_Cloud23.png)
- Task 4: Manage authentication and authorization for Azure Storage
![](Images/Day34_Cloud24.png)
![](Images/Day34_Cloud25.png)
I was a little impatient waiting for this to be allowed but it did work eventually.
![](Images/Day34_Cloud26.png)
- Task 5: Create and configure an Azure Files shares
On the run command this would not work with michael.cade@90DaysOfDevOps.com so I used my elevated account.
![](Images/Day34_Cloud27.png)
![](Images/Day34_Cloud28.png)
![](Images/Day34_Cloud29.png)
- Task 6: Manage network access for Azure Storage
![](Images/Day34_Cloud30.png)
### Serverless (Implement Web Apps)
Following [Module 09a](https://microsoftlearning.github.io/AZ-104-MicrosoftAzureAdministrator/Instructions/Labs/LAB_09a-Implement_Web_Apps.html):
- Task 1: Create an Azure web app
![](Images/Day34_Cloud31.png)
- Task 2: Create a staging deployment slot
![](Images/Day34_Cloud34.png)
- Task 3: Configure web app deployment settings
![](Images/Day34_Cloud33.png)
- Task 4: Deploy code to the staging deployment slot
![](Images/Day34_Cloud32.png)
- Task 5: Swap the staging slots
![](Images/Day34_Cloud35.png)
- Task 6: Configure and test autoscaling of the Azure web app
This script I am using can be found in (Cloud/05Serverless)
![](Images/Day34_Cloud36.png)
This wraps up the section on Microsoft Azure and the public cloud in general. I will say that I had lots of fun attacking and working through this scenarios.
## Resources
- [Hybrid Cloud and MultiCloud](https://www.youtube.com/watch?v=qkj5W98Xdvw)
- [Microsoft Azure Fundamentals](https://www.youtube.com/watch?v=NKEFWyqJ5XA&list=WL&index=130&t=12s)
- [Google Cloud Digital Leader Certification Course](https://www.youtube.com/watch?v=UGRDM86MBIQ&list=WL&index=131&t=10s)
- [AWS Basics for Beginners - Full Course](https://www.youtube.com/watch?v=ulprqHHWlng&t=5352s)
Next we will be diving into version control systems, specifically around git and then also code repository overviews and we will be choosing GitHub as this is my preferred option.
See you on [Day 35](day35.md)

View File

@ -58,11 +58,11 @@ This will not cover all things DevOps but it will cover the areas that I feel wi
- [✔️] ☁️ 31 > [Microsoft Azure Compute Models](Days/day31.md) - [✔️] ☁️ 31 > [Microsoft Azure Compute Models](Days/day31.md)
- [✔️] ☁️ 32 > [Microsoft Azure Storage & Database Models](Days/day32.md) - [✔️] ☁️ 32 > [Microsoft Azure Storage & Database Models](Days/day32.md)
- [✔️] ☁️ 33 > [Microsoft Azure Networking Models + Azure Management](Days/day33.md) - [✔️] ☁️ 33 > [Microsoft Azure Networking Models + Azure Management](Days/day33.md)
- [🚧] ☁️ 34 > [Microsoft Azure Hands-On Scenarios](Days/day34.md) - [✔️] ☁️ 34 > [Microsoft Azure Hands-On Scenarios](Days/day34.md)
### Use Git Effectively ### Use Git Effectively
- [] 📚 35 > [](Days/day35.md) - [🚧] 📚 35 > [](Days/day35.md)
- [] 📚 36 > [](Days/day36.md) - [] 📚 36 > [](Days/day36.md)
- [] 📚 37 > [](Days/day37.md) - [] 📚 37 > [](Days/day37.md)
- [] 📚 38 > [](Days/day38.md) - [] 📚 38 > [](Days/day38.md)