You have an Azure subscription named Subscription1. You sign in to the Azure portal and create a resource group named RG1. From documentation you have this command to create a VM: az vm create --resource-group RG1 --name VM1 --image UbuntuLTS --generate-ssh-keys. You need to create VM1 in Subscription1 by using this command. Solution: From the Azure portal, launch Azure Cloud Shell and select PowerShell, then run the command in Cloud Shell. Does this meet the goal?
Choose an answer
Tap an option to check your answer.
Correct answer: Yes.
Why this is the answer
Yes, this solution meets the goal. The Azure Cloud Shell provides a browser-based shell experience directly within the Azure portal, and it comes pre-configured with the Azure CLI (which the az vm create command uses) and Azure PowerShell. By launching Cloud Shell and selecting PowerShell, you can still execute Azure CLI commands because Cloud Shell supports both Bash and PowerShell environments, and the Azure CLI is available in both. The command will create VM1 in Subscription1 within the specified resource group RG1, as intended.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed