Compute types
Four ways to run code, each handing more to Azure
Virtual Machines, containers, App Service, Functions: each step leaves you less to look after.
Azure offers several ways to run your code, and the difference is how much of the stack stays with you. A virtual machine: a whole computer, rented. You look after the operating system, the runtime and the code. A container: your application packaged with its runtime. Azure looks after the host underneath. App Service: you upload a web application and Azure runs it. Functions: you write one function and Azure runs it when an event arrives, and bills for that run.
Compute types · Going deeper
Containers on Azure
Container Instances for one container, Container Apps for a few that scale, AKS for orchestration.
Virtual machines
One virtual machine is really five or six resources
A VM needs a disk, a network interface, a virtual network and a rule for which ports are open.
The study guide asks what resources a virtual machine requires. The machine itself, in a resource group and a region, with a size and an image. A disk for the operating system, and perhaps more for data. A network interface, which gives it a private address in a subnet of a virtual network. A network security group, which decides which ports are open. And, only if it must be reached from the internet, a public address.
Virtual machines · Going deeper
Virtual machine facts
A VM is infrastructure as a service, billed while it is allocated.
Check yourself
Code must run for a few seconds each time a file arrives, as shown. Which service fits, with the lowest cost?
Staying up and scaling
An availability set spreads machines, a scale set multiplies them
An availability set keeps VMs on separate racks. A scale set adds and removes identical VMs with the load.
Two features with similar names do different jobs. An availability set spreads your virtual machines over different racks in a datacentre. When one rack loses power, the machines on the other racks keep running: here, four of six. A Virtual Machine Scale Set is about quantity. It is a group of identical machines behind a load balancer, and Azure raises the count when the load rises and lowers it again afterwards.
Staying up and scaling · Going deeper
Fault domains and update domains
A fault domain is a rack. An update domain is a group restarted together.
Azure Virtual Desktop
The desktop runs in Azure and only the screen travels
Azure Virtual Desktop gives people a Windows desktop from any device, with the data kept in Azure.
One more virtual machine option is aimed at people, not servers. Staff use whatever device they have: a laptop, a phone, a browser. They connect to Azure Virtual Desktop, signing in with Microsoft Entra ID, and see a full Windows desktop that is running in Azure. Several users can share one virtual machine, and the applications and data never leave Azure, so nothing sensitive sits on the device.
Azure Virtual Desktop · Going deeper
App Service, and the three hosting options
App Service hosts web apps and APIs as a platform service. The options are web apps, containers and VMs.
Check yourself
Four virtual machines are in an availability set as shown. Rack 1 loses power. How many are still running?
Choosing
Four questions pick the host, most control first
Control of the OS: VM. A container: container services. A web app: App Service. An event: Functions.
To choose, ask four questions in order and stop at the first yes. Must you control the operating system? Then a virtual machine, or a scale set if you need many. Is the application already packaged as a container? Then one of the container services. Is it a web application or an A P I? App Service. Is it a short piece of code that reacts to an event? Functions.
Choosing · Going deeper
Clue words for compute
Each compute service has a clue phrase that the exam uses for it.
Check yourself
Which service meets every line of this requirement?
Lesson complete
You finished “Compute and application hosting on Azure”
Answer the questions along the way to see your score here.