Virtual Machine Args
data class VirtualMachineArgs(val extendedLocation: Output<ExtendedLocationArgs>? = null, val firmwareType: Output<Either<String, FirmwareType>>? = null, val hardwareProfile: Output<HardwareProfileArgs>? = null, val identity: Output<IdentityArgs>? = null, val inventoryItemId: Output<String>? = null, val kind: Output<String>? = null, val location: Output<String>? = null, val moRefId: Output<String>? = null, val networkProfile: Output<NetworkProfileArgs>? = null, val osProfile: Output<OsProfileArgs>? = null, val placementProfile: Output<PlacementProfileArgs>? = null, val resourceGroupName: Output<String>? = null, val resourcePoolId: Output<String>? = null, val smbiosUuid: Output<String>? = null, val storageProfile: Output<StorageProfileArgs>? = null, val tags: Output<Map<String, String>>? = null, val templateId: Output<String>? = null, val vCenterId: Output<String>? = null, val virtualMachineName: Output<String>? = null) : ConvertibleToJava<VirtualMachineArgs>
Define the virtualMachine. API Version: 2020-10-01-preview.
Example Usage
CreateVirtualMachine
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var virtualMachine = new AzureNative.ConnectedVMwarevSphere.VirtualMachine("virtualMachine", new()
{
ExtendedLocation = new AzureNative.ConnectedVMwarevSphere.Inputs.ExtendedLocationArgs
{
Name = "/subscriptions/a5015e1c-867f-4533-8541-85cd470d0cfb/resourceGroups/demoRG/providers/Microsoft.ExtendedLocation/customLocations/contoso",
Type = "customLocation",
},
HardwareProfile = new AzureNative.ConnectedVMwarevSphere.Inputs.HardwareProfileArgs
{
MemorySizeMB = 4196,
NumCPUs = 4,
},
Location = "East US",
ResourceGroupName = "testrg",
ResourcePoolId = "/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/ResourcePools/HRPool",
TemplateId = "/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/VirtualMachineTemplates/WebFrontEndTemplate",
VCenterId = "/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/VCenters/ContosoVCenter",
VirtualMachineName = "DemoVM",
});
});
Content copied to clipboard
package main
import (
connectedvmwarevsphere "github.com/pulumi/pulumi-azure-native-sdk/connectedvmwarevsphere"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := connectedvmwarevsphere.NewVirtualMachine(ctx, "virtualMachine", &connectedvmwarevsphere.VirtualMachineArgs{
ExtendedLocation: &connectedvmwarevsphere.ExtendedLocationArgs{
Name: pulumi.String("/subscriptions/a5015e1c-867f-4533-8541-85cd470d0cfb/resourceGroups/demoRG/providers/Microsoft.ExtendedLocation/customLocations/contoso"),
Type: pulumi.String("customLocation"),
},
HardwareProfile: &connectedvmwarevsphere.HardwareProfileArgs{
MemorySizeMB: pulumi.Int(4196),
NumCPUs: pulumi.Int(4),
},
Location: pulumi.String("East US"),
ResourceGroupName: pulumi.String("testrg"),
ResourcePoolId: pulumi.String("/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/ResourcePools/HRPool"),
TemplateId: pulumi.String("/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/VirtualMachineTemplates/WebFrontEndTemplate"),
VCenterId: pulumi.String("/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/VCenters/ContosoVCenter"),
VirtualMachineName: pulumi.String("DemoVM"),
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.connectedvmwarevsphere.VirtualMachine;
import com.pulumi.azurenative.connectedvmwarevsphere.VirtualMachineArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var virtualMachine = new VirtualMachine("virtualMachine", VirtualMachineArgs.builder()
.extendedLocation(Map.ofEntries(
Map.entry("name", "/subscriptions/a5015e1c-867f-4533-8541-85cd470d0cfb/resourceGroups/demoRG/providers/Microsoft.ExtendedLocation/customLocations/contoso"),
Map.entry("type", "customLocation")
))
.hardwareProfile(Map.ofEntries(
Map.entry("memorySizeMB", 4196),
Map.entry("numCPUs", 4)
))
.location("East US")
.resourceGroupName("testrg")
.resourcePoolId("/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/ResourcePools/HRPool")
.templateId("/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/VirtualMachineTemplates/WebFrontEndTemplate")
.vCenterId("/subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/VCenters/ContosoVCenter")
.virtualMachineName("DemoVM")
.build());
}
}
Content copied to clipboard
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:connectedvmwarevsphere:VirtualMachine DemoVM /subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.ConnectedVMwarevSphere/VirtualMachines/DemoVM
Content copied to clipboard
Constructors
Link copied to clipboard
constructor(extendedLocation: Output<ExtendedLocationArgs>? = null, firmwareType: Output<Either<String, FirmwareType>>? = null, hardwareProfile: Output<HardwareProfileArgs>? = null, identity: Output<IdentityArgs>? = null, inventoryItemId: Output<String>? = null, kind: Output<String>? = null, location: Output<String>? = null, moRefId: Output<String>? = null, networkProfile: Output<NetworkProfileArgs>? = null, osProfile: Output<OsProfileArgs>? = null, placementProfile: Output<PlacementProfileArgs>? = null, resourceGroupName: Output<String>? = null, resourcePoolId: Output<String>? = null, smbiosUuid: Output<String>? = null, storageProfile: Output<StorageProfileArgs>? = null, tags: Output<Map<String, String>>? = null, templateId: Output<String>? = null, vCenterId: Output<String>? = null, virtualMachineName: Output<String>? = null)
Properties
Link copied to clipboard
Gets or sets the extended location.
Link copied to clipboard
Firmware type
Link copied to clipboard
Hardware properties.
Link copied to clipboard
The identity of the resource.
Link copied to clipboard
Gets or sets the inventory Item ID for the virtual machine.
Link copied to clipboard
Network properties.
Link copied to clipboard
OS properties.
Link copied to clipboard
Placement properties.
Link copied to clipboard
The Resource Group Name.
Link copied to clipboard
Gets or sets the ARM Id of the resourcePool resource on which this virtual machine will deploy.
Link copied to clipboard
Gets or sets the SMBIOS UUID of the vm.
Link copied to clipboard
Storage properties.
Link copied to clipboard
Gets or sets the ARM Id of the template resource to deploy the virtual machine.
Link copied to clipboard
Name of the virtual machine resource.