Setup Visual Studio 2022 Development VM in Microsoft Azure 1

Sure, you could always install Visual Studio 2022 on your local machine, but there are times when a quick, easy to provision Virtual Machine with Visual Studio 2022 pre-installed may be very useful. First, you don’t need to install Visual Studio and can get developing on a new, clean machine in a matter of minutes. Also, you can easily create multiple Visual Studio 2022 VMs to have multiple isolated development environments for different project needs. There are a few benefits to running Visual Studio 2022 in a Virtual Machine. With Microsoft Azure it’s never been easier to spin up a Visual Studio 2022 VM, or multiple even, as necessary for your development needs. Now, let’s take a look at how to create a Visual Studio 2022 Virtual Machine in Microsoft Azure that you can connect to remotely using Microsoft Remote Desktop from any Operating System.


Setup Visual Studio 2022 VM in Azure

Before you go about provisioning a Visual Studio 2022 Virtual Machine in Azure, you’ll need an Azure Subscription. Once, you have than you will be able to find the Visual Studio 2022 virtual machine image in the Azure Marketplace.

Here’s a short guide to provisioning a new Visual Studio 2022 VM in Microsoft Azure:

  1. Navigate to the Azure Portal at https://portal.azure.com and login to your Azure Subscription.
  2. Navigate to the Azure Marketplace and search for Visual Studio 2022, then click on it in the list.
    Setup Visual Studio 2022 Development VM in Microsoft Azure 2
  3. Select the Visual Studio 2022 edition to install, then click Create.
    Setup Visual Studio 2022 Development VM in Microsoft Azure 3
  4. On the Create a virtual machine – Basics step, fill in the required values:
    • Resource group: Specify a Resource Group to provision the VM within
    • Virtual machine name: Specify a name for your VM
    • Region: You may specify the Azure Region to provision the VM within. It’s recommended that you use the nearest Azure Region to you geographically to minimize Internet latency when connecting to the VM.
    • Size: Specify the VM instance size to configure the CPU Core count and Memory (RAM) allocation for the VM. (I recommend you use a VM size with at minimum 2 CPUs, possibly more for better performance depending on your development needs.)
    • Administrator account: Specify the Username / Password to configure for the Administrator account on the VM. This will be used to login to it.
      Setup Visual Studio 2022 Development VM in Microsoft Azure 4
  5. For the Inbound port rules, make sure RDP (3389) inbound port is selected. This will be necessary to allow Remote Desktop connections to the VM so you can connect to it.
    Setup Visual Studio 2022 Development VM in Microsoft Azure 5
  6. Click Review + create.
  7. On the Review + create step, review the configurations selected, then click Create once it shows the green Validation passed message to begin provisioning the new Visual Studio 2022 Virtual Machine.
    Setup Visual Studio 2022 Development VM in Microsoft Azure 6
  8. It’s take a few minutes to complete the provisioning.

Congratulations on creating a Visual Studio 2022 development VM in Azure!

Connect with Remote Desktop

Once the Visual Studio 2022 VM is provisioned in Microsoft Azure, you will be able to connect to it using Microsoft Remote Desktop as you would any other Virtual Machine. You can find the Public IP Address for the VM on the Virtual Machine blade in the Azure Portal for the Visual Studio 2022 VM that you created.

On the Virtual Machine blade within the Azure Portal for your Visual Studio 2022 Virtual Machine, you can find the Connect with RDP information on the Connect pane. It also includes a button to be able to Download RDP File to make it easier to connect with Microsoft Remote Desktop without needing to copy/paste the VM IP Address.

Setup Visual Studio 2022 Development VM in Microsoft Azure 7

Azure-based Development VM Benefits

There are a few benefits from using an Azure-based (aka Cloud-based) development Virtual Machine.

  • Zero Install Required – You can easily create a new Windows VM with Visual Studio 2022 pre-installed in a matter of minutes; without requiring you to wait for the Visual Studio installer to set things up.
  • Minimal Hardware Issues – Since it’s a VM running on Azure infrastructure, you don’t need to worry about any hardware failures / issues like you might running on your local machine.
  • Easily Scale Up to Add CPU/Memory Resources – You can use the Azure Portal to easily scale the VM instance up to add more CPU/Memory as necessary by adjusting the VM Size. This also allows you to help control how much the VM hosting will cost.
  • Start/Stop VM On-demand to Save Cost – You can easily use the Azure Portal to Start/Stop the VM when necessary so you only pay for it to be allocated and run when you need it.
  • Device Agnostic – Azure VMs can be connected to using Microsoft Remote Desktop from any computer; regardless of the OS (Windows, Linux, macOS, or even tablets!) This allows you to easily interchange which physical “computer” you use to do your development work.

Happy developing in the cloud!

Microsoft MVP

Chris Pietschmann is a Microsoft MVP (Azure & IoT) and HashiCorp Ambassador (2021) with 20+ years of experience designing and building Cloud & Enterprise systems. He has worked with companies of all sizes from startups to Fortune 100. He is also a Microsoft Certified Azure Solutions Architect and developer, a Microsoft Certified Trainer (MCT), and Cloud Advocate. He has a passion for technology and sharing what he learns with others to help enable them to learn faster and be more productive.