All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azurenative.networkcloud.kotlin.VirtualMachineArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 2.82.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azurenative.networkcloud.kotlin

import com.pulumi.azurenative.networkcloud.VirtualMachineArgs.builder
import com.pulumi.azurenative.networkcloud.kotlin.enums.VirtualMachineBootMethod
import com.pulumi.azurenative.networkcloud.kotlin.enums.VirtualMachineDeviceModelType
import com.pulumi.azurenative.networkcloud.kotlin.enums.VirtualMachineIsolateEmulatorThread
import com.pulumi.azurenative.networkcloud.kotlin.enums.VirtualMachineVirtioInterfaceType
import com.pulumi.azurenative.networkcloud.kotlin.inputs.ExtendedLocationArgs
import com.pulumi.azurenative.networkcloud.kotlin.inputs.ExtendedLocationArgsBuilder
import com.pulumi.azurenative.networkcloud.kotlin.inputs.ImageRepositoryCredentialsArgs
import com.pulumi.azurenative.networkcloud.kotlin.inputs.ImageRepositoryCredentialsArgsBuilder
import com.pulumi.azurenative.networkcloud.kotlin.inputs.NetworkAttachmentArgs
import com.pulumi.azurenative.networkcloud.kotlin.inputs.NetworkAttachmentArgsBuilder
import com.pulumi.azurenative.networkcloud.kotlin.inputs.SshPublicKeyArgs
import com.pulumi.azurenative.networkcloud.kotlin.inputs.SshPublicKeyArgsBuilder
import com.pulumi.azurenative.networkcloud.kotlin.inputs.StorageProfileArgs
import com.pulumi.azurenative.networkcloud.kotlin.inputs.StorageProfileArgsBuilder
import com.pulumi.azurenative.networkcloud.kotlin.inputs.VirtualMachinePlacementHintArgs
import com.pulumi.azurenative.networkcloud.kotlin.inputs.VirtualMachinePlacementHintArgsBuilder
import com.pulumi.core.Either
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Double
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 *
 * Azure REST API version: 2023-10-01-preview. Prior API version in Azure Native 1.x: 2022-12-12-preview.
 * Other available API versions: 2023-07-01, 2024-06-01-preview.
 * ## Example Usage
 * ### Create or update virtual machine
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using AzureNative = Pulumi.AzureNative;
 * return await Deployment.RunAsync(() =>
 * {
 *     var virtualMachine = new AzureNative.NetworkCloud.VirtualMachine("virtualMachine", new()
 *     {
 *         AdminUsername = "username",
 *         BootMethod = AzureNative.NetworkCloud.VirtualMachineBootMethod.UEFI,
 *         CloudServicesNetworkAttachment = new AzureNative.NetworkCloud.Inputs.NetworkAttachmentArgs
 *         {
 *             AttachedNetworkId = "/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/cloudServicesNetworks/cloudServicesNetworkName",
 *             IpAllocationMethod = AzureNative.NetworkCloud.VirtualMachineIPAllocationMethod.Dynamic,
 *         },
 *         CpuCores = 2,
 *         ExtendedLocation = new AzureNative.NetworkCloud.Inputs.ExtendedLocationArgs
 *         {
 *             Name = "/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.ExtendedLocation/customLocations/clusterExtendedLocationName",
 *             Type = "CustomLocation",
 *         },
 *         Location = "location",
 *         MemorySizeGB = 8,
 *         NetworkAttachments = new[]
 *         {
 *             new AzureNative.NetworkCloud.Inputs.NetworkAttachmentArgs
 *             {
 *                 AttachedNetworkId = "/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/l3Networks/l3NetworkName",
 *                 DefaultGateway = AzureNative.NetworkCloud.DefaultGateway.True,
 *                 IpAllocationMethod = AzureNative.NetworkCloud.VirtualMachineIPAllocationMethod.Dynamic,
 *                 Ipv4Address = "198.51.100.1",
 *                 Ipv6Address = "2001:0db8:0000:0000:0000:0000:0000:0000",
 *                 NetworkAttachmentName = "netAttachName01",
 *             },
 *         },
 *         NetworkData = "bmV0d29ya0RhdGVTYW1wbGU=",
 *         PlacementHints = new[]
 *         {
 *             new AzureNative.NetworkCloud.Inputs.VirtualMachinePlacementHintArgs
 *             {
 *                 HintType = AzureNative.NetworkCloud.VirtualMachinePlacementHintType.Affinity,
 *                 ResourceId = "/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/racks/rackName",
 *                 SchedulingExecution = AzureNative.NetworkCloud.VirtualMachineSchedulingExecution.Hard,
 *                 Scope = "",
 *             },
 *         },
 *         ResourceGroupName = "resourceGroupName",
 *         SshPublicKeys = new[]
 *         {
 *             new AzureNative.NetworkCloud.Inputs.SshPublicKeyArgs
 *             {
 *                 KeyData = "ssh-rsa AAtsE3njSONzDYRIZv/WLjVuMfrUSByHp+jfaaOLHTIIB4fJvo6dQUZxE20w2iDHV3tEkmnTo84eba97VMueQD6OzJPEyWZMRpz8UYWOd0IXeRqiFu1lawNblZhwNT/ojNZfpB3af/YDzwQCZgTcTRyNNhL4o/blKUmug0daSsSXISTRnIDpcf5qytjs1Xo+yYyJMvzLL59mhAyb3p/cD+Y3/s3WhAx+l0XOKpzXnblrv9d3q4c2tWmm/SyFqthaqd0= admin@vm",
 *             },
 *         },
 *         StorageProfile = new AzureNative.NetworkCloud.Inputs.StorageProfileArgs
 *         {
 *             OsDisk = new AzureNative.NetworkCloud.Inputs.OsDiskArgs
 *             {
 *                 CreateOption = AzureNative.NetworkCloud.OsDiskCreateOption.Ephemeral,
 *                 DeleteOption = AzureNative.NetworkCloud.OsDiskDeleteOption.Delete,
 *                 DiskSizeGB = 120,
 *             },
 *             VolumeAttachments = new[]
 *             {
 *                 "/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/volumes/volumeName",
 *             },
 *         },
 *         Tags =
 *         {
 *             { "key1", "myvalue1" },
 *             { "key2", "myvalue2" },
 *         },
 *         UserData = "dXNlckRhdGVTYW1wbGU=",
 *         VirtualMachineName = "virtualMachineName",
 *         VmDeviceModel = AzureNative.NetworkCloud.VirtualMachineDeviceModelType.T2,
 *         VmImage = "myacr.azurecr.io/foobar:latest",
 *         VmImageRepositoryCredentials = new AzureNative.NetworkCloud.Inputs.ImageRepositoryCredentialsArgs
 *         {
 *             Password = "{password}",
 *             RegistryUrl = "myacr.azurecr.io",
 *             Username = "myuser",
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	networkcloud "github.com/pulumi/pulumi-azure-native-sdk/networkcloud/v2"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := networkcloud.NewVirtualMachine(ctx, "virtualMachine", &networkcloud.VirtualMachineArgs{
 * 			AdminUsername: pulumi.String("username"),
 * 			BootMethod:    pulumi.String(networkcloud.VirtualMachineBootMethodUEFI),
 * 			CloudServicesNetworkAttachment: &networkcloud.NetworkAttachmentArgs{
 * 				AttachedNetworkId:  pulumi.String("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/cloudServicesNetworks/cloudServicesNetworkName"),
 * 				IpAllocationMethod: pulumi.String(networkcloud.VirtualMachineIPAllocationMethodDynamic),
 * 			},
 * 			CpuCores: pulumi.Float64(2),
 * 			ExtendedLocation: &networkcloud.ExtendedLocationArgs{
 * 				Name: pulumi.String("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.ExtendedLocation/customLocations/clusterExtendedLocationName"),
 * 				Type: pulumi.String("CustomLocation"),
 * 			},
 * 			Location:     pulumi.String("location"),
 * 			MemorySizeGB: pulumi.Float64(8),
 * 			NetworkAttachments: networkcloud.NetworkAttachmentArray{
 * 				&networkcloud.NetworkAttachmentArgs{
 * 					AttachedNetworkId:     pulumi.String("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/l3Networks/l3NetworkName"),
 * 					DefaultGateway:        pulumi.String(networkcloud.DefaultGatewayTrue),
 * 					IpAllocationMethod:    pulumi.String(networkcloud.VirtualMachineIPAllocationMethodDynamic),
 * 					Ipv4Address:           pulumi.String("198.51.100.1"),
 * 					Ipv6Address:           pulumi.String("2001:0db8:0000:0000:0000:0000:0000:0000"),
 * 					NetworkAttachmentName: pulumi.String("netAttachName01"),
 * 				},
 * 			},
 * 			NetworkData: pulumi.String("bmV0d29ya0RhdGVTYW1wbGU="),
 * 			PlacementHints: networkcloud.VirtualMachinePlacementHintArray{
 * 				&networkcloud.VirtualMachinePlacementHintArgs{
 * 					HintType:            pulumi.String(networkcloud.VirtualMachinePlacementHintTypeAffinity),
 * 					ResourceId:          pulumi.String("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/racks/rackName"),
 * 					SchedulingExecution: pulumi.String(networkcloud.VirtualMachineSchedulingExecutionHard),
 * 					Scope:               pulumi.String(""),
 * 				},
 * 			},
 * 			ResourceGroupName: pulumi.String("resourceGroupName"),
 * 			SshPublicKeys: networkcloud.SshPublicKeyArray{
 * 				&networkcloud.SshPublicKeyArgs{
 * 					KeyData: pulumi.String("ssh-rsa AAtsE3njSONzDYRIZv/WLjVuMfrUSByHp+jfaaOLHTIIB4fJvo6dQUZxE20w2iDHV3tEkmnTo84eba97VMueQD6OzJPEyWZMRpz8UYWOd0IXeRqiFu1lawNblZhwNT/ojNZfpB3af/YDzwQCZgTcTRyNNhL4o/blKUmug0daSsSXISTRnIDpcf5qytjs1Xo+yYyJMvzLL59mhAyb3p/cD+Y3/s3WhAx+l0XOKpzXnblrv9d3q4c2tWmm/SyFqthaqd0= admin@vm"),
 * 				},
 * 			},
 * 			StorageProfile: &networkcloud.StorageProfileArgs{
 * 				OsDisk: &networkcloud.OsDiskArgs{
 * 					CreateOption: pulumi.String(networkcloud.OsDiskCreateOptionEphemeral),
 * 					DeleteOption: pulumi.String(networkcloud.OsDiskDeleteOptionDelete),
 * 					DiskSizeGB:   pulumi.Float64(120),
 * 				},
 * 				VolumeAttachments: pulumi.StringArray{
 * 					pulumi.String("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/volumes/volumeName"),
 * 				},
 * 			},
 * 			Tags: pulumi.StringMap{
 * 				"key1": pulumi.String("myvalue1"),
 * 				"key2": pulumi.String("myvalue2"),
 * 			},
 * 			UserData:           pulumi.String("dXNlckRhdGVTYW1wbGU="),
 * 			VirtualMachineName: pulumi.String("virtualMachineName"),
 * 			VmDeviceModel:      pulumi.String(networkcloud.VirtualMachineDeviceModelTypeT2),
 * 			VmImage:            pulumi.String("myacr.azurecr.io/foobar:latest"),
 * 			VmImageRepositoryCredentials: &networkcloud.ImageRepositoryCredentialsArgs{
 * 				Password:    pulumi.String("{password}"),
 * 				RegistryUrl: pulumi.String("myacr.azurecr.io"),
 * 				Username:    pulumi.String("myuser"),
 * 			},
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		return nil
 * 	})
 * }
 * ```
 * ```java
 * package generated_program;
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.networkcloud.VirtualMachine;
 * import com.pulumi.azurenative.networkcloud.VirtualMachineArgs;
 * import com.pulumi.azurenative.networkcloud.inputs.NetworkAttachmentArgs;
 * import com.pulumi.azurenative.networkcloud.inputs.ExtendedLocationArgs;
 * import com.pulumi.azurenative.networkcloud.inputs.VirtualMachinePlacementHintArgs;
 * import com.pulumi.azurenative.networkcloud.inputs.SshPublicKeyArgs;
 * import com.pulumi.azurenative.networkcloud.inputs.StorageProfileArgs;
 * import com.pulumi.azurenative.networkcloud.inputs.OsDiskArgs;
 * import com.pulumi.azurenative.networkcloud.inputs.ImageRepositoryCredentialsArgs;
 * 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()
 *             .adminUsername("username")
 *             .bootMethod("UEFI")
 *             .cloudServicesNetworkAttachment(NetworkAttachmentArgs.builder()
 *                 .attachedNetworkId("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/cloudServicesNetworks/cloudServicesNetworkName")
 *                 .ipAllocationMethod("Dynamic")
 *                 .build())
 *             .cpuCores(2)
 *             .extendedLocation(ExtendedLocationArgs.builder()
 *                 .name("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.ExtendedLocation/customLocations/clusterExtendedLocationName")
 *                 .type("CustomLocation")
 *                 .build())
 *             .location("location")
 *             .memorySizeGB(8)
 *             .networkAttachments(NetworkAttachmentArgs.builder()
 *                 .attachedNetworkId("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/l3Networks/l3NetworkName")
 *                 .defaultGateway("True")
 *                 .ipAllocationMethod("Dynamic")
 *                 .ipv4Address("198.51.100.1")
 *                 .ipv6Address("2001:0db8:0000:0000:0000:0000:0000:0000")
 *                 .networkAttachmentName("netAttachName01")
 *                 .build())
 *             .networkData("bmV0d29ya0RhdGVTYW1wbGU=")
 *             .placementHints(VirtualMachinePlacementHintArgs.builder()
 *                 .hintType("Affinity")
 *                 .resourceId("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/racks/rackName")
 *                 .schedulingExecution("Hard")
 *                 .scope("")
 *                 .build())
 *             .resourceGroupName("resourceGroupName")
 *             .sshPublicKeys(SshPublicKeyArgs.builder()
 *                 .keyData("ssh-rsa AAtsE3njSONzDYRIZv/WLjVuMfrUSByHp+jfaaOLHTIIB4fJvo6dQUZxE20w2iDHV3tEkmnTo84eba97VMueQD6OzJPEyWZMRpz8UYWOd0IXeRqiFu1lawNblZhwNT/ojNZfpB3af/YDzwQCZgTcTRyNNhL4o/blKUmug0daSsSXISTRnIDpcf5qytjs1Xo+yYyJMvzLL59mhAyb3p/cD+Y3/s3WhAx+l0XOKpzXnblrv9d3q4c2tWmm/SyFqthaqd0= admin@vm")
 *                 .build())
 *             .storageProfile(StorageProfileArgs.builder()
 *                 .osDisk(OsDiskArgs.builder()
 *                     .createOption("Ephemeral")
 *                     .deleteOption("Delete")
 *                     .diskSizeGB(120)
 *                     .build())
 *                 .volumeAttachments("/subscriptions/123e4567-e89b-12d3-a456-426655440000/resourceGroups/resourceGroupName/providers/Microsoft.NetworkCloud/volumes/volumeName")
 *                 .build())
 *             .tags(Map.ofEntries(
 *                 Map.entry("key1", "myvalue1"),
 *                 Map.entry("key2", "myvalue2")
 *             ))
 *             .userData("dXNlckRhdGVTYW1wbGU=")
 *             .virtualMachineName("virtualMachineName")
 *             .vmDeviceModel("T2")
 *             .vmImage("myacr.azurecr.io/foobar:latest")
 *             .vmImageRepositoryCredentials(ImageRepositoryCredentialsArgs.builder()
 *                 .password("{password}")
 *                 .registryUrl("myacr.azurecr.io")
 *                 .username("myuser")
 *                 .build())
 *             .build());
 *     }
 * }
 * ```
 * ## Import
 * An existing resource can be imported using its type token, name, and identifier, e.g.
 * ```sh
 * $ pulumi import azure-native:networkcloud:VirtualMachine virtualMachineName /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkCloud/virtualMachines/{virtualMachineName}
 * ```
 * @property adminUsername The name of the administrator to which the ssh public keys will be added into the authorized keys.
 * @property bootMethod Selects the boot method for the virtual machine.
 * @property cloudServicesNetworkAttachment The cloud service network that provides platform-level services for the virtual machine.
 * @property cpuCores The number of CPU cores in the virtual machine.
 * @property extendedLocation The extended location of the cluster associated with the resource.
 * @property isolateEmulatorThread Field Deprecated, the value will be ignored if provided. The indicator of whether one of the specified CPU cores is isolated to run the emulator thread for this virtual machine.
 * @property location The geo-location where the resource lives
 * @property memorySizeGB The memory size of the virtual machine in GB.
 * @property networkAttachments The list of network attachments to the virtual machine.
 * @property networkData The Base64 encoded cloud-init network data.
 * @property placementHints The scheduling hints for the virtual machine.
 * @property resourceGroupName The name of the resource group. The name is case insensitive.
 * @property sshPublicKeys The list of ssh public keys. Each key will be added to the virtual machine using the cloud-init ssh_authorized_keys mechanism for the adminUsername.
 * @property storageProfile The storage profile that specifies size and other parameters about the disks related to the virtual machine.
 * @property tags Resource tags.
 * @property userData The Base64 encoded cloud-init user data.
 * @property virtioInterface Field Deprecated, use virtualizationModel instead. The type of the virtio interface.
 * @property virtualMachineName The name of the virtual machine.
 * @property vmDeviceModel The type of the device model to use.
 * @property vmImage The virtual machine image that is currently provisioned to the OS disk, using the full url and tag notation used to pull the image.
 * @property vmImageRepositoryCredentials The credentials used to login to the image repository that has access to the specified image.
 */
public data class VirtualMachineArgs(
    public val adminUsername: Output? = null,
    public val bootMethod: Output>? = null,
    public val cloudServicesNetworkAttachment: Output? = null,
    public val cpuCores: Output? = null,
    public val extendedLocation: Output? = null,
    public val isolateEmulatorThread: Output>? =
        null,
    public val location: Output? = null,
    public val memorySizeGB: Output? = null,
    public val networkAttachments: Output>? = null,
    public val networkData: Output? = null,
    public val placementHints: Output>? = null,
    public val resourceGroupName: Output? = null,
    public val sshPublicKeys: Output>? = null,
    public val storageProfile: Output? = null,
    public val tags: Output>? = null,
    public val userData: Output? = null,
    public val virtioInterface: Output>? = null,
    public val virtualMachineName: Output? = null,
    public val vmDeviceModel: Output>? = null,
    public val vmImage: Output? = null,
    public val vmImageRepositoryCredentials: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.networkcloud.VirtualMachineArgs =
        com.pulumi.azurenative.networkcloud.VirtualMachineArgs.builder()
            .adminUsername(adminUsername?.applyValue({ args0 -> args0 }))
            .bootMethod(
                bootMethod?.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .cloudServicesNetworkAttachment(
                cloudServicesNetworkAttachment?.applyValue({ args0 ->
                    args0.let({ args0 -> args0.toJava() })
                }),
            )
            .cpuCores(cpuCores?.applyValue({ args0 -> args0 }))
            .extendedLocation(extendedLocation?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .isolateEmulatorThread(
                isolateEmulatorThread?.applyValue({ args0 ->
                    args0.transform({ args0 ->
                        args0
                    }, { args0 -> args0.let({ args0 -> args0.toJava() }) })
                }),
            )
            .location(location?.applyValue({ args0 -> args0 }))
            .memorySizeGB(memorySizeGB?.applyValue({ args0 -> args0 }))
            .networkAttachments(
                networkAttachments?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .networkData(networkData?.applyValue({ args0 -> args0 }))
            .placementHints(
                placementHints?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
            .sshPublicKeys(
                sshPublicKeys?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .storageProfile(storageProfile?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .tags(tags?.applyValue({ args0 -> args0.map({ args0 -> args0.key.to(args0.value) }).toMap() }))
            .userData(userData?.applyValue({ args0 -> args0 }))
            .virtioInterface(
                virtioInterface?.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .virtualMachineName(virtualMachineName?.applyValue({ args0 -> args0 }))
            .vmDeviceModel(
                vmDeviceModel?.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .vmImage(vmImage?.applyValue({ args0 -> args0 }))
            .vmImageRepositoryCredentials(
                vmImageRepositoryCredentials?.applyValue({ args0 ->
                    args0.let({ args0 -> args0.toJava() })
                }),
            ).build()
}

/**
 * Builder for [VirtualMachineArgs].
 */
@PulumiTagMarker
public class VirtualMachineArgsBuilder internal constructor() {
    private var adminUsername: Output? = null

    private var bootMethod: Output>? = null

    private var cloudServicesNetworkAttachment: Output? = null

    private var cpuCores: Output? = null

    private var extendedLocation: Output? = null

    private var isolateEmulatorThread: Output>? =
        null

    private var location: Output? = null

    private var memorySizeGB: Output? = null

    private var networkAttachments: Output>? = null

    private var networkData: Output? = null

    private var placementHints: Output>? = null

    private var resourceGroupName: Output? = null

    private var sshPublicKeys: Output>? = null

    private var storageProfile: Output? = null

    private var tags: Output>? = null

    private var userData: Output? = null

    private var virtioInterface: Output>? = null

    private var virtualMachineName: Output? = null

    private var vmDeviceModel: Output>? = null

    private var vmImage: Output? = null

    private var vmImageRepositoryCredentials: Output? = null

    /**
     * @param value The name of the administrator to which the ssh public keys will be added into the authorized keys.
     */
    @JvmName("dyqpeojlmehpxbra")
    public suspend fun adminUsername(`value`: Output) {
        this.adminUsername = value
    }

    /**
     * @param value Selects the boot method for the virtual machine.
     */
    @JvmName("ocouklqfghfmwrvd")
    public suspend fun bootMethod(`value`: Output>) {
        this.bootMethod = value
    }

    /**
     * @param value The cloud service network that provides platform-level services for the virtual machine.
     */
    @JvmName("grlvnbhwmtinwkgl")
    public suspend fun cloudServicesNetworkAttachment(`value`: Output) {
        this.cloudServicesNetworkAttachment = value
    }

    /**
     * @param value The number of CPU cores in the virtual machine.
     */
    @JvmName("cvgvcnhmfumvdbsu")
    public suspend fun cpuCores(`value`: Output) {
        this.cpuCores = value
    }

    /**
     * @param value The extended location of the cluster associated with the resource.
     */
    @JvmName("ctstjpbxnxogsucq")
    public suspend fun extendedLocation(`value`: Output) {
        this.extendedLocation = value
    }

    /**
     * @param value Field Deprecated, the value will be ignored if provided. The indicator of whether one of the specified CPU cores is isolated to run the emulator thread for this virtual machine.
     */
    @JvmName("jxtafuoeelrrbhql")
    public suspend fun isolateEmulatorThread(`value`: Output>) {
        this.isolateEmulatorThread = value
    }

    /**
     * @param value The geo-location where the resource lives
     */
    @JvmName("ysqntdtkonmcsfho")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value The memory size of the virtual machine in GB.
     */
    @JvmName("qfjpcukovkvmbddp")
    public suspend fun memorySizeGB(`value`: Output) {
        this.memorySizeGB = value
    }

    /**
     * @param value The list of network attachments to the virtual machine.
     */
    @JvmName("hmfkmothudbcnjcs")
    public suspend fun networkAttachments(`value`: Output>) {
        this.networkAttachments = value
    }

    @JvmName("hfjiifqutydewhbq")
    public suspend fun networkAttachments(vararg values: Output) {
        this.networkAttachments = Output.all(values.asList())
    }

    /**
     * @param values The list of network attachments to the virtual machine.
     */
    @JvmName("unfvmxiynwjyclud")
    public suspend fun networkAttachments(values: List>) {
        this.networkAttachments = Output.all(values)
    }

    /**
     * @param value The Base64 encoded cloud-init network data.
     */
    @JvmName("auaagvyclvetbmht")
    public suspend fun networkData(`value`: Output) {
        this.networkData = value
    }

    /**
     * @param value The scheduling hints for the virtual machine.
     */
    @JvmName("euxnhhmomorehccj")
    public suspend fun placementHints(`value`: Output>) {
        this.placementHints = value
    }

    @JvmName("qigwpavjnwxulwyh")
    public suspend fun placementHints(vararg values: Output) {
        this.placementHints = Output.all(values.asList())
    }

    /**
     * @param values The scheduling hints for the virtual machine.
     */
    @JvmName("xvwumthveledrfit")
    public suspend fun placementHints(values: List>) {
        this.placementHints = Output.all(values)
    }

    /**
     * @param value The name of the resource group. The name is case insensitive.
     */
    @JvmName("bislyarokqreufry")
    public suspend fun resourceGroupName(`value`: Output) {
        this.resourceGroupName = value
    }

    /**
     * @param value The list of ssh public keys. Each key will be added to the virtual machine using the cloud-init ssh_authorized_keys mechanism for the adminUsername.
     */
    @JvmName("rruyqnywfbdgtlst")
    public suspend fun sshPublicKeys(`value`: Output>) {
        this.sshPublicKeys = value
    }

    @JvmName("hkqqdlkwhwyympaq")
    public suspend fun sshPublicKeys(vararg values: Output) {
        this.sshPublicKeys = Output.all(values.asList())
    }

    /**
     * @param values The list of ssh public keys. Each key will be added to the virtual machine using the cloud-init ssh_authorized_keys mechanism for the adminUsername.
     */
    @JvmName("qgsvpavantfhfcnn")
    public suspend fun sshPublicKeys(values: List>) {
        this.sshPublicKeys = Output.all(values)
    }

    /**
     * @param value The storage profile that specifies size and other parameters about the disks related to the virtual machine.
     */
    @JvmName("asdbsiondnburajt")
    public suspend fun storageProfile(`value`: Output) {
        this.storageProfile = value
    }

    /**
     * @param value Resource tags.
     */
    @JvmName("fclwxkcoruacowyh")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value The Base64 encoded cloud-init user data.
     */
    @JvmName("dpiqgpbacedbpwja")
    public suspend fun userData(`value`: Output) {
        this.userData = value
    }

    /**
     * @param value Field Deprecated, use virtualizationModel instead. The type of the virtio interface.
     */
    @JvmName("bgbptrqquoapohfv")
    public suspend fun virtioInterface(`value`: Output>) {
        this.virtioInterface = value
    }

    /**
     * @param value The name of the virtual machine.
     */
    @JvmName("eiuwgwgtlmbrprlw")
    public suspend fun virtualMachineName(`value`: Output) {
        this.virtualMachineName = value
    }

    /**
     * @param value The type of the device model to use.
     */
    @JvmName("mmlhjrjogdxqoekh")
    public suspend fun vmDeviceModel(`value`: Output>) {
        this.vmDeviceModel = value
    }

    /**
     * @param value The virtual machine image that is currently provisioned to the OS disk, using the full url and tag notation used to pull the image.
     */
    @JvmName("yomejirqgycxnons")
    public suspend fun vmImage(`value`: Output) {
        this.vmImage = value
    }

    /**
     * @param value The credentials used to login to the image repository that has access to the specified image.
     */
    @JvmName("lalcwegomyufdsxt")
    public suspend fun vmImageRepositoryCredentials(`value`: Output) {
        this.vmImageRepositoryCredentials = value
    }

    /**
     * @param value The name of the administrator to which the ssh public keys will be added into the authorized keys.
     */
    @JvmName("bvhxntghlrwlktea")
    public suspend fun adminUsername(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.adminUsername = mapped
    }

    /**
     * @param value Selects the boot method for the virtual machine.
     */
    @JvmName("bfmiqujhdjadgxwu")
    public suspend fun bootMethod(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.bootMethod = mapped
    }

    /**
     * @param value Selects the boot method for the virtual machine.
     */
    @JvmName("fmvgorhugljcpnwa")
    public fun bootMethod(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.bootMethod = mapped
    }

    /**
     * @param value Selects the boot method for the virtual machine.
     */
    @JvmName("bloobwmxdxjvntyb")
    public fun bootMethod(`value`: VirtualMachineBootMethod) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.bootMethod = mapped
    }

    /**
     * @param value The cloud service network that provides platform-level services for the virtual machine.
     */
    @JvmName("oiqikeboqmrngkog")
    public suspend fun cloudServicesNetworkAttachment(`value`: NetworkAttachmentArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cloudServicesNetworkAttachment = mapped
    }

    /**
     * @param argument The cloud service network that provides platform-level services for the virtual machine.
     */
    @JvmName("rxsidxllyigpapqx")
    public suspend fun cloudServicesNetworkAttachment(argument: suspend NetworkAttachmentArgsBuilder.() -> Unit) {
        val toBeMapped = NetworkAttachmentArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.cloudServicesNetworkAttachment = mapped
    }

    /**
     * @param value The number of CPU cores in the virtual machine.
     */
    @JvmName("iyyydghfcfjnkrde")
    public suspend fun cpuCores(`value`: Double?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cpuCores = mapped
    }

    /**
     * @param value The extended location of the cluster associated with the resource.
     */
    @JvmName("jwbyofqivfcacqua")
    public suspend fun extendedLocation(`value`: ExtendedLocationArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.extendedLocation = mapped
    }

    /**
     * @param argument The extended location of the cluster associated with the resource.
     */
    @JvmName("tngtppwaiuvnirmi")
    public suspend fun extendedLocation(argument: suspend ExtendedLocationArgsBuilder.() -> Unit) {
        val toBeMapped = ExtendedLocationArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.extendedLocation = mapped
    }

    /**
     * @param value Field Deprecated, the value will be ignored if provided. The indicator of whether one of the specified CPU cores is isolated to run the emulator thread for this virtual machine.
     */
    @JvmName("wkdtpmdwaelfrtrc")
    public suspend fun isolateEmulatorThread(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.isolateEmulatorThread = mapped
    }

    /**
     * @param value Field Deprecated, the value will be ignored if provided. The indicator of whether one of the specified CPU cores is isolated to run the emulator thread for this virtual machine.
     */
    @JvmName("amqotoxhbfweumcx")
    public fun isolateEmulatorThread(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.isolateEmulatorThread = mapped
    }

    /**
     * @param value Field Deprecated, the value will be ignored if provided. The indicator of whether one of the specified CPU cores is isolated to run the emulator thread for this virtual machine.
     */
    @JvmName("kdcnboyalupoopne")
    public fun isolateEmulatorThread(`value`: VirtualMachineIsolateEmulatorThread) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.isolateEmulatorThread = mapped
    }

    /**
     * @param value The geo-location where the resource lives
     */
    @JvmName("yveofyamdinnkaix")
    public suspend fun location(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param value The memory size of the virtual machine in GB.
     */
    @JvmName("jflflfyuituvcuna")
    public suspend fun memorySizeGB(`value`: Double?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.memorySizeGB = mapped
    }

    /**
     * @param value The list of network attachments to the virtual machine.
     */
    @JvmName("ngbwiulqduwamltk")
    public suspend fun networkAttachments(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.networkAttachments = mapped
    }

    /**
     * @param argument The list of network attachments to the virtual machine.
     */
    @JvmName("yxnoeabulotouoxo")
    public suspend fun networkAttachments(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            NetworkAttachmentArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.networkAttachments = mapped
    }

    /**
     * @param argument The list of network attachments to the virtual machine.
     */
    @JvmName("xlmfwxpgkxlvluai")
    public suspend fun networkAttachments(vararg argument: suspend NetworkAttachmentArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            NetworkAttachmentArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.networkAttachments = mapped
    }

    /**
     * @param argument The list of network attachments to the virtual machine.
     */
    @JvmName("mdslkcmytwhoerlo")
    public suspend fun networkAttachments(argument: suspend NetworkAttachmentArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(NetworkAttachmentArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.networkAttachments = mapped
    }

    /**
     * @param values The list of network attachments to the virtual machine.
     */
    @JvmName("btglkqxjqpummuaa")
    public suspend fun networkAttachments(vararg values: NetworkAttachmentArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.networkAttachments = mapped
    }

    /**
     * @param value The Base64 encoded cloud-init network data.
     */
    @JvmName("ndvawoayjoiqtcax")
    public suspend fun networkData(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.networkData = mapped
    }

    /**
     * @param value The scheduling hints for the virtual machine.
     */
    @JvmName("oigmttfhfcpwsadv")
    public suspend fun placementHints(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.placementHints = mapped
    }

    /**
     * @param argument The scheduling hints for the virtual machine.
     */
    @JvmName("jortcmcnkwicmgbe")
    public suspend fun placementHints(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            VirtualMachinePlacementHintArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.placementHints = mapped
    }

    /**
     * @param argument The scheduling hints for the virtual machine.
     */
    @JvmName("bofwnhiumvsknjyk")
    public suspend fun placementHints(vararg argument: suspend VirtualMachinePlacementHintArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            VirtualMachinePlacementHintArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.placementHints = mapped
    }

    /**
     * @param argument The scheduling hints for the virtual machine.
     */
    @JvmName("cdjiwsddrqpdvwrb")
    public suspend fun placementHints(argument: suspend VirtualMachinePlacementHintArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            VirtualMachinePlacementHintArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.placementHints = mapped
    }

    /**
     * @param values The scheduling hints for the virtual machine.
     */
    @JvmName("egnhsgjjrkumhvbw")
    public suspend fun placementHints(vararg values: VirtualMachinePlacementHintArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.placementHints = mapped
    }

    /**
     * @param value The name of the resource group. The name is case insensitive.
     */
    @JvmName("jynwwyxemqxacjhw")
    public suspend fun resourceGroupName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceGroupName = mapped
    }

    /**
     * @param value The list of ssh public keys. Each key will be added to the virtual machine using the cloud-init ssh_authorized_keys mechanism for the adminUsername.
     */
    @JvmName("pxalgdvuxikhjqss")
    public suspend fun sshPublicKeys(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sshPublicKeys = mapped
    }

    /**
     * @param argument The list of ssh public keys. Each key will be added to the virtual machine using the cloud-init ssh_authorized_keys mechanism for the adminUsername.
     */
    @JvmName("kquipkyeualcladq")
    public suspend fun sshPublicKeys(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            SshPublicKeyArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.sshPublicKeys = mapped
    }

    /**
     * @param argument The list of ssh public keys. Each key will be added to the virtual machine using the cloud-init ssh_authorized_keys mechanism for the adminUsername.
     */
    @JvmName("dddijvjftgffqlyu")
    public suspend fun sshPublicKeys(vararg argument: suspend SshPublicKeyArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            SshPublicKeyArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.sshPublicKeys = mapped
    }

    /**
     * @param argument The list of ssh public keys. Each key will be added to the virtual machine using the cloud-init ssh_authorized_keys mechanism for the adminUsername.
     */
    @JvmName("akwjfuuxvqusscyc")
    public suspend fun sshPublicKeys(argument: suspend SshPublicKeyArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(SshPublicKeyArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.sshPublicKeys = mapped
    }

    /**
     * @param values The list of ssh public keys. Each key will be added to the virtual machine using the cloud-init ssh_authorized_keys mechanism for the adminUsername.
     */
    @JvmName("ygeqmmkoatynjliw")
    public suspend fun sshPublicKeys(vararg values: SshPublicKeyArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.sshPublicKeys = mapped
    }

    /**
     * @param value The storage profile that specifies size and other parameters about the disks related to the virtual machine.
     */
    @JvmName("hbvflhnjwloviwgr")
    public suspend fun storageProfile(`value`: StorageProfileArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.storageProfile = mapped
    }

    /**
     * @param argument The storage profile that specifies size and other parameters about the disks related to the virtual machine.
     */
    @JvmName("lvrfcjvlduufqkhq")
    public suspend fun storageProfile(argument: suspend StorageProfileArgsBuilder.() -> Unit) {
        val toBeMapped = StorageProfileArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.storageProfile = mapped
    }

    /**
     * @param value Resource tags.
     */
    @JvmName("edrcbksfcclxlkur")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values Resource tags.
     */
    @JvmName("hgyqpfebkppofbvx")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param value The Base64 encoded cloud-init user data.
     */
    @JvmName("skqwaeoaffajemnh")
    public suspend fun userData(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.userData = mapped
    }

    /**
     * @param value Field Deprecated, use virtualizationModel instead. The type of the virtio interface.
     */
    @JvmName("exviypbdvoojslat")
    public suspend fun virtioInterface(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.virtioInterface = mapped
    }

    /**
     * @param value Field Deprecated, use virtualizationModel instead. The type of the virtio interface.
     */
    @JvmName("byieejyssrvvmppp")
    public fun virtioInterface(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.virtioInterface = mapped
    }

    /**
     * @param value Field Deprecated, use virtualizationModel instead. The type of the virtio interface.
     */
    @JvmName("pxwrtpakorffsnav")
    public fun virtioInterface(`value`: VirtualMachineVirtioInterfaceType) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.virtioInterface = mapped
    }

    /**
     * @param value The name of the virtual machine.
     */
    @JvmName("borrmgjxrmacdwgk")
    public suspend fun virtualMachineName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.virtualMachineName = mapped
    }

    /**
     * @param value The type of the device model to use.
     */
    @JvmName("jmasppcndtxkidvr")
    public suspend fun vmDeviceModel(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.vmDeviceModel = mapped
    }

    /**
     * @param value The type of the device model to use.
     */
    @JvmName("mdnhxesssrfqvglr")
    public fun vmDeviceModel(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.vmDeviceModel = mapped
    }

    /**
     * @param value The type of the device model to use.
     */
    @JvmName("dthxqdbkdaxmaldm")
    public fun vmDeviceModel(`value`: VirtualMachineDeviceModelType) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.vmDeviceModel = mapped
    }

    /**
     * @param value The virtual machine image that is currently provisioned to the OS disk, using the full url and tag notation used to pull the image.
     */
    @JvmName("bxvmutygibiugfjg")
    public suspend fun vmImage(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.vmImage = mapped
    }

    /**
     * @param value The credentials used to login to the image repository that has access to the specified image.
     */
    @JvmName("gytcddxyqjpukqta")
    public suspend fun vmImageRepositoryCredentials(`value`: ImageRepositoryCredentialsArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.vmImageRepositoryCredentials = mapped
    }

    /**
     * @param argument The credentials used to login to the image repository that has access to the specified image.
     */
    @JvmName("dnbdnttwoodurota")
    public suspend fun vmImageRepositoryCredentials(argument: suspend ImageRepositoryCredentialsArgsBuilder.() -> Unit) {
        val toBeMapped = ImageRepositoryCredentialsArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.vmImageRepositoryCredentials = mapped
    }

    internal fun build(): VirtualMachineArgs = VirtualMachineArgs(
        adminUsername = adminUsername,
        bootMethod = bootMethod,
        cloudServicesNetworkAttachment = cloudServicesNetworkAttachment,
        cpuCores = cpuCores,
        extendedLocation = extendedLocation,
        isolateEmulatorThread = isolateEmulatorThread,
        location = location,
        memorySizeGB = memorySizeGB,
        networkAttachments = networkAttachments,
        networkData = networkData,
        placementHints = placementHints,
        resourceGroupName = resourceGroupName,
        sshPublicKeys = sshPublicKeys,
        storageProfile = storageProfile,
        tags = tags,
        userData = userData,
        virtioInterface = virtioInterface,
        virtualMachineName = virtualMachineName,
        vmDeviceModel = vmDeviceModel,
        vmImage = vmImage,
        vmImageRepositoryCredentials = vmImageRepositoryCredentials,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy