Manage Azure Resources with Visual Studio Cloud Explorer
If you need to manage more than just a few Azure resources, then Visual Studio Cloud Explorer might be the tool for you. In this Ask the Admin, I will give you a quick guided tour.
Microsoft’s Azure cloud platform is large and complex. It is expanding every month with new features. Love it or hate it, the web management portal’s system of panels is the primary method for managing Azure resources. Of course, you can stick with the classic portal, which at some point will be retired. There is also the Azure command-line interface (CLI) and PowerShell but neither offers a visual way to quickly explore resources.
Visual Studio 2017 includes a tool called Cloud Explorer, which provides a hierarchical view of Azure resources. This is not dissimilar from traditional management consoles that you might be familiar with in a Windows Server. Active Directory Users and Computers (ADUC) is an example of this. Visual Studio is not a tool for sysadmins. Bring on the advent of cloud computing and resources that can be programmatically provisioned. Visual Studio is a DevOps tool you should not overlook. In addition to Cloud Explorer, Visual Studio is also useful for working with JSON Azure Resource Manager (ARM) templates. Cloud Explorer is ARM based. It cannot see resources deployed using the classic model.
For more information on using Visual Studio to create and edit ARM templates, see Using VS Code to Edit Azure JSON Templates on the Petri IT Knowledgebase. If you want to see a primer or Resource Groups, see What Are Microsoft Azure Resource Groups? on Petri.
Using Cloud Explorer
The first step is to make sure you have Visual Studio 2017 installed on your management PC. I recommend that you install the free Community Edition. This is good if you do not have a license for the Professional or Enterprise editions. You can download Visual Studio from Microsoft’s website here. The only other requirement is that you select the Azure Development workload during the install process.
When you open Visual Studio for the first time, you will be asked to enter the Microsoft Account details associated with your Visual Studio profile. If you have never used Visual Studio before, a profile will be created to store settings. You will have the same experience anytime you sign in to Visual Studio.
- Open Visual Studio. Click the View menu and select Cloud Explorer.
After a few seconds, the Cloud Explorer pane will open on the left. Let’s decide which Azure subscriptions to load into Cloud Explorer. Remember, that one Microsoft Account can be associated with multiple Azure subscriptions.
- Click the Accounts icon at the top of the Cloud Explorer pane.
- If you need to add an account, other than the one you used to sign into Visual Studio, click Add an account. Enter your account credentials.
- Select the subscriptions you want to add to Cloud Explorer and then click Apply.
A list of resources in the selected subscriptions will soon appear in the Cloud Explorer pane. I am particularly interested in navigating storage accounts.
- Expand the subscription you want to navigate, which is Storage Accounts. Select the storage account you want to explore. You can keep drilling down through blob containers. Make sure you expand your Azure subscription in Cloud Explorer and not Local. This is the first node.
- Double click a blob container. It will appear in the Blob Container Editor in the center of Visual Studio. It will show any blobs in the container.
At the top of the editor pane, there are some controls that allow you to upload and download blobs from and to the container and local PC. Unfortunately, there is no way to copy blobs between containers. To do this, you will need to use the command-line tool AzCopy or there is a standalone tool for Windows, Mac, and Linux. This is called Microsoft Azure Storage Explorer that you can download here. For more information on using AzCopy, see How to Copy a Virtual Hard Disk in Microsoft Azure on Petri.
Cloud Explorer defaults to displaying resources by resource type. If you look in the top left, you can change this setting to Resource Groups. There is also a search box so that you can find resources quickly by name.
Expanding the virtual machines node allows you to select a virtual machine and perform various actions in the pane at the bottom of Cloud Explorer. By doing this, you can start and stop the virtual machine. Additionally, you can switch to the properties tab and get more detailed information about the resource.
Cloud Explorer is aimed more at developers than sysadmins. Resources like App Services have a much wider range of available actions. Nevertheless, it does provide a useful way to view resources and understand what you have in your subscription.