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

com.pulumi.googlenative.compute.v1.kotlin.inputs.InstancePropertiesArgs.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.

The newest version!
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.googlenative.compute.v1.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.googlenative.compute.v1.inputs.InstancePropertiesArgs.builder
import com.pulumi.googlenative.compute.v1.kotlin.enums.InstancePropertiesKeyRevocationActionType
import com.pulumi.googlenative.compute.v1.kotlin.enums.InstancePropertiesPrivateIpv6GoogleAccess
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 *
 * @property advancedMachineFeatures Controls for advanced machine-related behavior features. Note that for MachineImage, this is not supported yet.
 * @property canIpForward Enables instances created based on these properties to send packets with source IP addresses other than their own and receive packets with destination IP addresses other than their own. If these instances will be used as an IP gateway or it will be set as the next-hop in a Route resource, specify true. If unsure, leave this set to false. See the Enable IP forwarding documentation for more information.
 * @property confidentialInstanceConfig Specifies the Confidential Instance options. Note that for MachineImage, this is not supported yet.
 * @property description An optional text description for the instances that are created from these properties.
 * @property disks An array of disks that are associated with the instances that are created from these properties.
 * @property guestAccelerators A list of guest accelerator cards' type and count to use for instances created from these properties.
 * @property keyRevocationActionType KeyRevocationActionType of the instance. Supported options are "STOP" and "NONE". The default value is "NONE" if it is not specified.
 * @property labels Labels to apply to instances that are created from these properties.
 * @property machineType The machine type to use for instances that are created from these properties.
 * @property metadata The metadata key/value pairs to assign to instances that are created from these properties. These pairs can consist of custom metadata or predefined keys. See Project and instance metadata for more information.
 * @property minCpuPlatform Minimum cpu/platform to be used by instances. The instance may be scheduled on the specified or newer cpu/platform. Applicable values are the friendly names of CPU platforms, such as minCpuPlatform: "Intel Haswell" or minCpuPlatform: "Intel Sandy Bridge". For more information, read Specifying a Minimum CPU Platform.
 * @property networkInterfaces An array of network access configurations for this interface.
 * @property networkPerformanceConfig Note that for MachineImage, this is not supported yet.
 * @property privateIpv6GoogleAccess The private IPv6 google access type for VMs. If not specified, use INHERIT_FROM_SUBNETWORK as default. Note that for MachineImage, this is not supported yet.
 * @property reservationAffinity Specifies the reservations that instances can consume from. Note that for MachineImage, this is not supported yet.
 * @property resourceManagerTags Resource manager tags to be bound to the instance. Tag keys and values have the same definition as resource manager tags. Keys must be in the format `tagKeys/{tag_key_id}`, and values are in the format `tagValues/456`. The field is ignored (both PUT & PATCH) when empty.
 * @property resourcePolicies Resource policies (names, not URLs) applied to instances created from these properties. Note that for MachineImage, this is not supported yet.
 * @property scheduling Specifies the scheduling options for the instances that are created from these properties.
 * @property serviceAccounts A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from these properties. Use metadata queries to obtain the access tokens for these instances.
 * @property shieldedInstanceConfig Note that for MachineImage, this is not supported yet.
 * @property tags A list of tags to apply to the instances that are created from these properties. The tags identify valid sources or targets for network firewalls. The setTags method can modify this list of tags. Each tag within the list must comply with RFC1035.
 */
public data class InstancePropertiesArgs(
    public val advancedMachineFeatures: Output? = null,
    public val canIpForward: Output? = null,
    public val confidentialInstanceConfig: Output? = null,
    public val description: Output? = null,
    public val disks: Output>? = null,
    public val guestAccelerators: Output>? = null,
    public val keyRevocationActionType: Output? = null,
    public val labels: Output>? = null,
    public val machineType: Output? = null,
    public val metadata: Output? = null,
    public val minCpuPlatform: Output? = null,
    public val networkInterfaces: Output>? = null,
    public val networkPerformanceConfig: Output? = null,
    public val privateIpv6GoogleAccess: Output? = null,
    public val reservationAffinity: Output? = null,
    public val resourceManagerTags: Output>? = null,
    public val resourcePolicies: Output>? = null,
    public val scheduling: Output? = null,
    public val serviceAccounts: Output>? = null,
    public val shieldedInstanceConfig: Output? = null,
    public val tags: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.googlenative.compute.v1.inputs.InstancePropertiesArgs =
        com.pulumi.googlenative.compute.v1.inputs.InstancePropertiesArgs.builder()
            .advancedMachineFeatures(
                advancedMachineFeatures?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .canIpForward(canIpForward?.applyValue({ args0 -> args0 }))
            .confidentialInstanceConfig(
                confidentialInstanceConfig?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .description(description?.applyValue({ args0 -> args0 }))
            .disks(disks?.applyValue({ args0 -> args0.map({ args0 -> args0.let({ args0 -> args0.toJava() }) }) }))
            .guestAccelerators(
                guestAccelerators?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .keyRevocationActionType(
                keyRevocationActionType?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .labels(labels?.applyValue({ args0 -> args0.map({ args0 -> args0.key.to(args0.value) }).toMap() }))
            .machineType(machineType?.applyValue({ args0 -> args0 }))
            .metadata(metadata?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .minCpuPlatform(minCpuPlatform?.applyValue({ args0 -> args0 }))
            .networkInterfaces(
                networkInterfaces?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .networkPerformanceConfig(
                networkPerformanceConfig?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .privateIpv6GoogleAccess(
                privateIpv6GoogleAccess?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .reservationAffinity(
                reservationAffinity?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .resourceManagerTags(
                resourceManagerTags?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            )
            .resourcePolicies(resourcePolicies?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .scheduling(scheduling?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .serviceAccounts(
                serviceAccounts?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .shieldedInstanceConfig(
                shieldedInstanceConfig?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .tags(tags?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) })).build()
}

/**
 * Builder for [InstancePropertiesArgs].
 */
@PulumiTagMarker
public class InstancePropertiesArgsBuilder internal constructor() {
    private var advancedMachineFeatures: Output? = null

    private var canIpForward: Output? = null

    private var confidentialInstanceConfig: Output? = null

    private var description: Output? = null

    private var disks: Output>? = null

    private var guestAccelerators: Output>? = null

    private var keyRevocationActionType: Output? = null

    private var labels: Output>? = null

    private var machineType: Output? = null

    private var metadata: Output? = null

    private var minCpuPlatform: Output? = null

    private var networkInterfaces: Output>? = null

    private var networkPerformanceConfig: Output? = null

    private var privateIpv6GoogleAccess: Output? = null

    private var reservationAffinity: Output? = null

    private var resourceManagerTags: Output>? = null

    private var resourcePolicies: Output>? = null

    private var scheduling: Output? = null

    private var serviceAccounts: Output>? = null

    private var shieldedInstanceConfig: Output? = null

    private var tags: Output? = null

    /**
     * @param value Controls for advanced machine-related behavior features. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("hkpgojtromfwelcd")
    public suspend fun advancedMachineFeatures(`value`: Output) {
        this.advancedMachineFeatures = value
    }

    /**
     * @param value Enables instances created based on these properties to send packets with source IP addresses other than their own and receive packets with destination IP addresses other than their own. If these instances will be used as an IP gateway or it will be set as the next-hop in a Route resource, specify true. If unsure, leave this set to false. See the Enable IP forwarding documentation for more information.
     */
    @JvmName("utmwwaqgosxcbvvt")
    public suspend fun canIpForward(`value`: Output) {
        this.canIpForward = value
    }

    /**
     * @param value Specifies the Confidential Instance options. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("pmuukildyjetnfqg")
    public suspend fun confidentialInstanceConfig(`value`: Output) {
        this.confidentialInstanceConfig = value
    }

    /**
     * @param value An optional text description for the instances that are created from these properties.
     */
    @JvmName("nxokosxagtptslxs")
    public suspend fun description(`value`: Output) {
        this.description = value
    }

    /**
     * @param value An array of disks that are associated with the instances that are created from these properties.
     */
    @JvmName("hejmleuqjwuqwoym")
    public suspend fun disks(`value`: Output>) {
        this.disks = value
    }

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

    /**
     * @param values An array of disks that are associated with the instances that are created from these properties.
     */
    @JvmName("hjbdicbsiecxlcwv")
    public suspend fun disks(values: List>) {
        this.disks = Output.all(values)
    }

    /**
     * @param value A list of guest accelerator cards' type and count to use for instances created from these properties.
     */
    @JvmName("jfomfycooknybokw")
    public suspend fun guestAccelerators(`value`: Output>) {
        this.guestAccelerators = value
    }

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

    /**
     * @param values A list of guest accelerator cards' type and count to use for instances created from these properties.
     */
    @JvmName("mwnvrohgbrjtulkn")
    public suspend fun guestAccelerators(values: List>) {
        this.guestAccelerators = Output.all(values)
    }

    /**
     * @param value KeyRevocationActionType of the instance. Supported options are "STOP" and "NONE". The default value is "NONE" if it is not specified.
     */
    @JvmName("xdsyonwpbirwynvf")
    public suspend fun keyRevocationActionType(`value`: Output) {
        this.keyRevocationActionType = value
    }

    /**
     * @param value Labels to apply to instances that are created from these properties.
     */
    @JvmName("iiouuysyfdfsksmo")
    public suspend fun labels(`value`: Output>) {
        this.labels = value
    }

    /**
     * @param value The machine type to use for instances that are created from these properties.
     */
    @JvmName("ydbndgnrtfifquxx")
    public suspend fun machineType(`value`: Output) {
        this.machineType = value
    }

    /**
     * @param value The metadata key/value pairs to assign to instances that are created from these properties. These pairs can consist of custom metadata or predefined keys. See Project and instance metadata for more information.
     */
    @JvmName("ieoqskxfugwfdkci")
    public suspend fun metadata(`value`: Output) {
        this.metadata = value
    }

    /**
     * @param value Minimum cpu/platform to be used by instances. The instance may be scheduled on the specified or newer cpu/platform. Applicable values are the friendly names of CPU platforms, such as minCpuPlatform: "Intel Haswell" or minCpuPlatform: "Intel Sandy Bridge". For more information, read Specifying a Minimum CPU Platform.
     */
    @JvmName("qwtruaqcaehdghip")
    public suspend fun minCpuPlatform(`value`: Output) {
        this.minCpuPlatform = value
    }

    /**
     * @param value An array of network access configurations for this interface.
     */
    @JvmName("rtvsqwlgivjgncya")
    public suspend fun networkInterfaces(`value`: Output>) {
        this.networkInterfaces = value
    }

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

    /**
     * @param values An array of network access configurations for this interface.
     */
    @JvmName("oslqnjdhxaudmpna")
    public suspend fun networkInterfaces(values: List>) {
        this.networkInterfaces = Output.all(values)
    }

    /**
     * @param value Note that for MachineImage, this is not supported yet.
     */
    @JvmName("bjgrpntuniytprkm")
    public suspend fun networkPerformanceConfig(`value`: Output) {
        this.networkPerformanceConfig = value
    }

    /**
     * @param value The private IPv6 google access type for VMs. If not specified, use INHERIT_FROM_SUBNETWORK as default. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("thxstwmvpmvhtubf")
    public suspend fun privateIpv6GoogleAccess(`value`: Output) {
        this.privateIpv6GoogleAccess = value
    }

    /**
     * @param value Specifies the reservations that instances can consume from. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("rinhyslytivnlowi")
    public suspend fun reservationAffinity(`value`: Output) {
        this.reservationAffinity = value
    }

    /**
     * @param value Resource manager tags to be bound to the instance. Tag keys and values have the same definition as resource manager tags. Keys must be in the format `tagKeys/{tag_key_id}`, and values are in the format `tagValues/456`. The field is ignored (both PUT & PATCH) when empty.
     */
    @JvmName("lsjugyhsyojtttya")
    public suspend fun resourceManagerTags(`value`: Output>) {
        this.resourceManagerTags = value
    }

    /**
     * @param value Resource policies (names, not URLs) applied to instances created from these properties. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("hhlcpxajnbdjkpmf")
    public suspend fun resourcePolicies(`value`: Output>) {
        this.resourcePolicies = value
    }

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

    /**
     * @param values Resource policies (names, not URLs) applied to instances created from these properties. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("npvjdsecpueweisd")
    public suspend fun resourcePolicies(values: List>) {
        this.resourcePolicies = Output.all(values)
    }

    /**
     * @param value Specifies the scheduling options for the instances that are created from these properties.
     */
    @JvmName("nuiibgoaexhhsona")
    public suspend fun scheduling(`value`: Output) {
        this.scheduling = value
    }

    /**
     * @param value A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from these properties. Use metadata queries to obtain the access tokens for these instances.
     */
    @JvmName("hqqflcmtqqiiuftp")
    public suspend fun serviceAccounts(`value`: Output>) {
        this.serviceAccounts = value
    }

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

    /**
     * @param values A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from these properties. Use metadata queries to obtain the access tokens for these instances.
     */
    @JvmName("tegujomqupwwexiu")
    public suspend fun serviceAccounts(values: List>) {
        this.serviceAccounts = Output.all(values)
    }

    /**
     * @param value Note that for MachineImage, this is not supported yet.
     */
    @JvmName("fvmselxpcicuwbow")
    public suspend fun shieldedInstanceConfig(`value`: Output) {
        this.shieldedInstanceConfig = value
    }

    /**
     * @param value A list of tags to apply to the instances that are created from these properties. The tags identify valid sources or targets for network firewalls. The setTags method can modify this list of tags. Each tag within the list must comply with RFC1035.
     */
    @JvmName("xvnvfbxskyghfffs")
    public suspend fun tags(`value`: Output) {
        this.tags = value
    }

    /**
     * @param value Controls for advanced machine-related behavior features. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("wrbwfvygfnnahhio")
    public suspend fun advancedMachineFeatures(`value`: AdvancedMachineFeaturesArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.advancedMachineFeatures = mapped
    }

    /**
     * @param argument Controls for advanced machine-related behavior features. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("cvvweddmchlswurh")
    public suspend fun advancedMachineFeatures(argument: suspend AdvancedMachineFeaturesArgsBuilder.() -> Unit) {
        val toBeMapped = AdvancedMachineFeaturesArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.advancedMachineFeatures = mapped
    }

    /**
     * @param value Enables instances created based on these properties to send packets with source IP addresses other than their own and receive packets with destination IP addresses other than their own. If these instances will be used as an IP gateway or it will be set as the next-hop in a Route resource, specify true. If unsure, leave this set to false. See the Enable IP forwarding documentation for more information.
     */
    @JvmName("xgbdvdebnhhhlckv")
    public suspend fun canIpForward(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.canIpForward = mapped
    }

    /**
     * @param value Specifies the Confidential Instance options. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("oxcukdmxkdbuhmnm")
    public suspend fun confidentialInstanceConfig(`value`: ConfidentialInstanceConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.confidentialInstanceConfig = mapped
    }

    /**
     * @param argument Specifies the Confidential Instance options. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("ievwgcfyokkcfnhn")
    public suspend fun confidentialInstanceConfig(argument: suspend ConfidentialInstanceConfigArgsBuilder.() -> Unit) {
        val toBeMapped = ConfidentialInstanceConfigArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.confidentialInstanceConfig = mapped
    }

    /**
     * @param value An optional text description for the instances that are created from these properties.
     */
    @JvmName("gdgoveiirqrmqwgp")
    public suspend fun description(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.description = mapped
    }

    /**
     * @param value An array of disks that are associated with the instances that are created from these properties.
     */
    @JvmName("rfhuktdmfqdjcxlc")
    public suspend fun disks(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.disks = mapped
    }

    /**
     * @param argument An array of disks that are associated with the instances that are created from these properties.
     */
    @JvmName("yultufxnglsjopfb")
    public suspend fun disks(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            AttachedDiskArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.disks = mapped
    }

    /**
     * @param argument An array of disks that are associated with the instances that are created from these properties.
     */
    @JvmName("rxcvjqhbynjjvswo")
    public suspend fun disks(vararg argument: suspend AttachedDiskArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            AttachedDiskArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.disks = mapped
    }

    /**
     * @param argument An array of disks that are associated with the instances that are created from these properties.
     */
    @JvmName("midncqinqgtssyas")
    public suspend fun disks(argument: suspend AttachedDiskArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(AttachedDiskArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.disks = mapped
    }

    /**
     * @param values An array of disks that are associated with the instances that are created from these properties.
     */
    @JvmName("dapjdylmgblryepo")
    public suspend fun disks(vararg values: AttachedDiskArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.disks = mapped
    }

    /**
     * @param value A list of guest accelerator cards' type and count to use for instances created from these properties.
     */
    @JvmName("lbawhrjjidwjuxmb")
    public suspend fun guestAccelerators(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.guestAccelerators = mapped
    }

    /**
     * @param argument A list of guest accelerator cards' type and count to use for instances created from these properties.
     */
    @JvmName("jpepkbhraxnfwwkr")
    public suspend fun guestAccelerators(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            AcceleratorConfigArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.guestAccelerators = mapped
    }

    /**
     * @param argument A list of guest accelerator cards' type and count to use for instances created from these properties.
     */
    @JvmName("qyxqayyppxawjryy")
    public suspend fun guestAccelerators(vararg argument: suspend AcceleratorConfigArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            AcceleratorConfigArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.guestAccelerators = mapped
    }

    /**
     * @param argument A list of guest accelerator cards' type and count to use for instances created from these properties.
     */
    @JvmName("ctkfybeqmgpjtgsr")
    public suspend fun guestAccelerators(argument: suspend AcceleratorConfigArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(AcceleratorConfigArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.guestAccelerators = mapped
    }

    /**
     * @param values A list of guest accelerator cards' type and count to use for instances created from these properties.
     */
    @JvmName("yalctyesausmwtwk")
    public suspend fun guestAccelerators(vararg values: AcceleratorConfigArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.guestAccelerators = mapped
    }

    /**
     * @param value KeyRevocationActionType of the instance. Supported options are "STOP" and "NONE". The default value is "NONE" if it is not specified.
     */
    @JvmName("mortcvicakxyhylw")
    public suspend fun keyRevocationActionType(`value`: InstancePropertiesKeyRevocationActionType?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.keyRevocationActionType = mapped
    }

    /**
     * @param value Labels to apply to instances that are created from these properties.
     */
    @JvmName("eklwkbgwykcxfyrb")
    public suspend fun labels(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.labels = mapped
    }

    /**
     * @param values Labels to apply to instances that are created from these properties.
     */
    @JvmName("vqotjnmapyhnlaxb")
    public fun labels(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.labels = mapped
    }

    /**
     * @param value The machine type to use for instances that are created from these properties.
     */
    @JvmName("mcehmdsgtnhngswf")
    public suspend fun machineType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.machineType = mapped
    }

    /**
     * @param value The metadata key/value pairs to assign to instances that are created from these properties. These pairs can consist of custom metadata or predefined keys. See Project and instance metadata for more information.
     */
    @JvmName("grptgeeynvvoffwa")
    public suspend fun metadata(`value`: MetadataArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.metadata = mapped
    }

    /**
     * @param argument The metadata key/value pairs to assign to instances that are created from these properties. These pairs can consist of custom metadata or predefined keys. See Project and instance metadata for more information.
     */
    @JvmName("bblhqllwxkykymkt")
    public suspend fun metadata(argument: suspend MetadataArgsBuilder.() -> Unit) {
        val toBeMapped = MetadataArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.metadata = mapped
    }

    /**
     * @param value Minimum cpu/platform to be used by instances. The instance may be scheduled on the specified or newer cpu/platform. Applicable values are the friendly names of CPU platforms, such as minCpuPlatform: "Intel Haswell" or minCpuPlatform: "Intel Sandy Bridge". For more information, read Specifying a Minimum CPU Platform.
     */
    @JvmName("miwulyvmwlgcljcu")
    public suspend fun minCpuPlatform(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.minCpuPlatform = mapped
    }

    /**
     * @param value An array of network access configurations for this interface.
     */
    @JvmName("lrirpyqpbiiugxwe")
    public suspend fun networkInterfaces(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.networkInterfaces = mapped
    }

    /**
     * @param argument An array of network access configurations for this interface.
     */
    @JvmName("ycafuxrtntgolqct")
    public suspend fun networkInterfaces(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            NetworkInterfaceArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.networkInterfaces = mapped
    }

    /**
     * @param argument An array of network access configurations for this interface.
     */
    @JvmName("kjkfsynmlsmiuxtu")
    public suspend fun networkInterfaces(vararg argument: suspend NetworkInterfaceArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            NetworkInterfaceArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.networkInterfaces = mapped
    }

    /**
     * @param argument An array of network access configurations for this interface.
     */
    @JvmName("tnxtxolagmydkokv")
    public suspend fun networkInterfaces(argument: suspend NetworkInterfaceArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(NetworkInterfaceArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.networkInterfaces = mapped
    }

    /**
     * @param values An array of network access configurations for this interface.
     */
    @JvmName("fbcwsrmbeuacihbo")
    public suspend fun networkInterfaces(vararg values: NetworkInterfaceArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.networkInterfaces = mapped
    }

    /**
     * @param value Note that for MachineImage, this is not supported yet.
     */
    @JvmName("khujfkkjidwvejke")
    public suspend fun networkPerformanceConfig(`value`: NetworkPerformanceConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.networkPerformanceConfig = mapped
    }

    /**
     * @param argument Note that for MachineImage, this is not supported yet.
     */
    @JvmName("goymvflpkhnjqscq")
    public suspend fun networkPerformanceConfig(argument: suspend NetworkPerformanceConfigArgsBuilder.() -> Unit) {
        val toBeMapped = NetworkPerformanceConfigArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.networkPerformanceConfig = mapped
    }

    /**
     * @param value The private IPv6 google access type for VMs. If not specified, use INHERIT_FROM_SUBNETWORK as default. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("tvoiitekdjrfmhdr")
    public suspend fun privateIpv6GoogleAccess(`value`: InstancePropertiesPrivateIpv6GoogleAccess?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.privateIpv6GoogleAccess = mapped
    }

    /**
     * @param value Specifies the reservations that instances can consume from. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("moybsfsbnneotmvr")
    public suspend fun reservationAffinity(`value`: ReservationAffinityArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.reservationAffinity = mapped
    }

    /**
     * @param argument Specifies the reservations that instances can consume from. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("qkabxbnylevpybqi")
    public suspend fun reservationAffinity(argument: suspend ReservationAffinityArgsBuilder.() -> Unit) {
        val toBeMapped = ReservationAffinityArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.reservationAffinity = mapped
    }

    /**
     * @param value Resource manager tags to be bound to the instance. Tag keys and values have the same definition as resource manager tags. Keys must be in the format `tagKeys/{tag_key_id}`, and values are in the format `tagValues/456`. The field is ignored (both PUT & PATCH) when empty.
     */
    @JvmName("wokodsqodynyatlg")
    public suspend fun resourceManagerTags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceManagerTags = mapped
    }

    /**
     * @param values Resource manager tags to be bound to the instance. Tag keys and values have the same definition as resource manager tags. Keys must be in the format `tagKeys/{tag_key_id}`, and values are in the format `tagValues/456`. The field is ignored (both PUT & PATCH) when empty.
     */
    @JvmName("fecpbpkmctqxtust")
    public fun resourceManagerTags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.resourceManagerTags = mapped
    }

    /**
     * @param value Resource policies (names, not URLs) applied to instances created from these properties. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("tdouerdysoastsin")
    public suspend fun resourcePolicies(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourcePolicies = mapped
    }

    /**
     * @param values Resource policies (names, not URLs) applied to instances created from these properties. Note that for MachineImage, this is not supported yet.
     */
    @JvmName("kiqxgurmqbgykmiq")
    public suspend fun resourcePolicies(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.resourcePolicies = mapped
    }

    /**
     * @param value Specifies the scheduling options for the instances that are created from these properties.
     */
    @JvmName("cfjrhamxsgqdhpox")
    public suspend fun scheduling(`value`: SchedulingArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.scheduling = mapped
    }

    /**
     * @param argument Specifies the scheduling options for the instances that are created from these properties.
     */
    @JvmName("iebxwmlwengxpoah")
    public suspend fun scheduling(argument: suspend SchedulingArgsBuilder.() -> Unit) {
        val toBeMapped = SchedulingArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.scheduling = mapped
    }

    /**
     * @param value A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from these properties. Use metadata queries to obtain the access tokens for these instances.
     */
    @JvmName("nenryaefsqhqkkdg")
    public suspend fun serviceAccounts(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.serviceAccounts = mapped
    }

    /**
     * @param argument A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from these properties. Use metadata queries to obtain the access tokens for these instances.
     */
    @JvmName("tpkreqkxauonrgno")
    public suspend fun serviceAccounts(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ServiceAccountArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.serviceAccounts = mapped
    }

    /**
     * @param argument A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from these properties. Use metadata queries to obtain the access tokens for these instances.
     */
    @JvmName("jwsspmmnlcqqtcmx")
    public suspend fun serviceAccounts(vararg argument: suspend ServiceAccountArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ServiceAccountArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.serviceAccounts = mapped
    }

    /**
     * @param argument A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from these properties. Use metadata queries to obtain the access tokens for these instances.
     */
    @JvmName("xhflbogpgvltfqrv")
    public suspend fun serviceAccounts(argument: suspend ServiceAccountArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(ServiceAccountArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.serviceAccounts = mapped
    }

    /**
     * @param values A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from these properties. Use metadata queries to obtain the access tokens for these instances.
     */
    @JvmName("waxacsncbicqnkxa")
    public suspend fun serviceAccounts(vararg values: ServiceAccountArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.serviceAccounts = mapped
    }

    /**
     * @param value Note that for MachineImage, this is not supported yet.
     */
    @JvmName("vhqgxapmqqwhjtgr")
    public suspend fun shieldedInstanceConfig(`value`: ShieldedInstanceConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.shieldedInstanceConfig = mapped
    }

    /**
     * @param argument Note that for MachineImage, this is not supported yet.
     */
    @JvmName("svlpjrhlejnqjgks")
    public suspend fun shieldedInstanceConfig(argument: suspend ShieldedInstanceConfigArgsBuilder.() -> Unit) {
        val toBeMapped = ShieldedInstanceConfigArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.shieldedInstanceConfig = mapped
    }

    /**
     * @param value A list of tags to apply to the instances that are created from these properties. The tags identify valid sources or targets for network firewalls. The setTags method can modify this list of tags. Each tag within the list must comply with RFC1035.
     */
    @JvmName("cmgsuuklkardcwfi")
    public suspend fun tags(`value`: TagsArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param argument A list of tags to apply to the instances that are created from these properties. The tags identify valid sources or targets for network firewalls. The setTags method can modify this list of tags. Each tag within the list must comply with RFC1035.
     */
    @JvmName("xwttmhsaxuvcboqh")
    public suspend fun tags(argument: suspend TagsArgsBuilder.() -> Unit) {
        val toBeMapped = TagsArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.tags = mapped
    }

    internal fun build(): InstancePropertiesArgs = InstancePropertiesArgs(
        advancedMachineFeatures = advancedMachineFeatures,
        canIpForward = canIpForward,
        confidentialInstanceConfig = confidentialInstanceConfig,
        description = description,
        disks = disks,
        guestAccelerators = guestAccelerators,
        keyRevocationActionType = keyRevocationActionType,
        labels = labels,
        machineType = machineType,
        metadata = metadata,
        minCpuPlatform = minCpuPlatform,
        networkInterfaces = networkInterfaces,
        networkPerformanceConfig = networkPerformanceConfig,
        privateIpv6GoogleAccess = privateIpv6GoogleAccess,
        reservationAffinity = reservationAffinity,
        resourceManagerTags = resourceManagerTags,
        resourcePolicies = resourcePolicies,
        scheduling = scheduling,
        serviceAccounts = serviceAccounts,
        shieldedInstanceConfig = shieldedInstanceConfig,
        tags = tags,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy