Quantcast
Channel: Azure Virtual Machines forum
Viewing all articles
Browse latest Browse all 12545

how to retrieve details of the deployed virtual machine.

$
0
0
Hi,

I am using Resource manager  templates to deploy a virtual machine. I would like to retrieve the disk related details of the deployed virual machine. I am following as suggested in https://docs.microsoft.com/en-us/azure/virtual-machines/virtual-machines-windows-csharp-manage.

I am using the below method as suggsted in the link.

But ComputeManagementClient does not accept TokenCredentials credential. It is looking for Microsoft.Azure.SubscriptionCloudCredentials.

Cant we use Microsoft.Rest.TokenCredentials ? Thanks in advance


public static async void GetVirtualMachineAsync( TokenCredentials credential, string groupName, string vmName, string subscriptionId) { Console.WriteLine("Getting information about the virtual machine..."); var computeManagementClient = new ComputeManagementClient(credential) { SubscriptionId = subscriptionId };



Balu


Viewing all articles
Browse latest Browse all 12545

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>