Azure: Building up basic knowledge [Workshop]

azure cloud azure-portal azure-vm azure-share azure-container-instances devops

1. Introduction

The intention of this workshop is to:

2. Key Facts

Title: Azure: Building up basic knowledge [Workshop]
Location: Graz, Smart City - Waagner-Biro Strasse 108
Date: 2022-09-29
github.com repository: https://github.com/patkoch/azureworkshop

3. Prerequisites

Just bring your own laptop, ensure a current browser is installed - you’ll get WiFi access and a power supply.

4. Exercises - Hands-on session

4.1 Create an Azure Virtual Machine and establish a connection to a File Share

This exercise is about to create an Azure Virtual Machine and to establish a connection to an Azure File Share by using PowerShell functions. The PowerShell functions mount the File Share and call a simple Windows Console Application, which is located at the File Share.

4.1.1 YouTube Tutorial

4.1.2 Manual - Step by Step Explanation

Starting point is the Azure Portal:

01_AzurePortal

There choose “Virtual machines” or search for it in the search input field at the top:

02_ClickatVM

Select “Azure virtual machine”:

03_CreateNew

Now the form appears for defining the virtual machine. Create a new resource group, named “rg-azXX”, replace the “XX” with your “az” number, e.g. “01”. After that, confirm it with “OK”.

04_CreateNewRGduetoAZNumber

Define a name for the virtual machine. Name it like “demo-vm-azXX”. Again, replace the “XX” with your provided “az” number:

05_EnterNameduetoAZNumber

Select “Windows 10 Pro, version 21H2 - Gen2” as operating system:

06_ChooseWindowsOS

Set following size for the virtual machine size:

07_DefineVMSize

Provide credentials to the virtual machine, use “azXX” for the username, replace the “XX” with your “az” number. Enter a password of your choice and remember it.

08_SetCredentials

After that, click at “Review + create”:

09_ReviewCreate

Wait until the validation has passed, after that, click at “Create”:

10_ValidationPassed

Wait until the deployment is complete:

11_SelectCreate

After that, the virtual machine deployed.

12_WaittillDeploymentComplete

Switch to the Storage Account “azgrazworkshopstorage”. This includes a File Share named “azgrazworkshop”:

13_Storage-Account-FileShare

Click at “azgrazshare”:

14_SelectShare

Click at “Connect”:

15_SelectConnect

There choose “Windows” and a drive letter of your choice - in that case “Z”:

16_SelectWindowsDriveLetter

Select “Show Script” for getting the desired script, which establishes a connection to the File Share by using a PowerShell script:

17_SelectShowScript

Click at the icon in the right lower corner for copying the script:

18_CopyScript

Switch back to the Virtual Machine, on the left choose “Run command” and select “RunPowerShellScript”:

19_BackToVM-RunCommand

Paste the script and enter in addition line 11 for calling the executable:

20_InsertScript

Finally, click at “Run” and wait for the exection:

21_Result

4.2 Create an Azure Container Instance

This exercise is about to deploy Azure Container Instances using a Windows Container Image.

4.2.1 Manual - Step by Step Explanation

The source of the Azure Container Instance - the Container Image - is located at an Azure Container Registry named “azgrazworkshop”:

01-ACRpng

Click at “Repositories” and at “az-windows-container-simple”:

02-ACR-Repo

The tag of the Container is “1.0”:

03-ACR-Image

Switch back to the overview of the Azure Portal and click at “Container instances”:

04-Choose-ACI

Select “create”:

05-ClickCreate.png

The Azure Container Instance can be defined in this form. Create a new “Resource group”:

06-CreateNewRG

Name it like “rg-aci-azXX”: replace the “XX” with your “az” number:

07-CreateNewRG

Provide a name for the Container: name it like “aci-container-azXX” - replace the “XX” with your “az” number.

08-EnterContainerName

Choose “Azure Container Registry” as source for the image:

09-EnterChooseImageSource

Verify, that following settings are done:

10-ACR

Change the size and set 4 GiB as memory - confirm it with “OK”:

11-ChangeSize

Finally, click at “Review + create”:

12-ReviewCreate

Wait until the deployment is complete:

13-DeploymentComplete

Click at “Go to resource”:

14-GoToResource

Click at “Containers” - this show the running Container:

15-ACI-Containers

Click at “Logs” for showing the output:

16-Logs

Click at “Connect” and insert “cmd” for accessing the Container:

17-Connect

The attachment to the Container is done:

18-Connect-Result

5. How to arrive

If you’d like to arrive by using public transport, take line 6 (Smart City) get out at “Dreiersch├╝tzengasse/Helmut-List-Halle” and follow the way of the blue dotted line:

map

Just go straight forward and pass the gate:

asc_01

We’ll meet us at the door below the “AVL” icon. There you’ll get your access card for entering the building:

asc_02