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

com.pulumi.azure.compute.kotlin.inputs.LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs.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: 6.15.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azure.compute.kotlin.inputs

import com.pulumi.azure.compute.inputs.LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property applicationGatewayBackendAddressPoolIds A list of Backend Address Pools ID's from a Application Gateway which this Virtual Machine Scale Set should be connected to.
 * @property applicationSecurityGroupIds A list of Application Security Group ID's which this Virtual Machine Scale Set should be connected to.
 * @property loadBalancerBackendAddressPoolIds A list of Backend Address Pools ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
 * > **Note:**  When the Virtual Machine Scale Set is configured to have public IPs per instance are created with a load balancer, the SKU of the Virtual Machine instance IPs is determined by the SKU of the Virtual Machine Scale Sets Load Balancer (e.g. `Basic` or `Standard`). Alternatively, you may use the `public_ip_prefix_id` field to generate instance-level IPs in a virtual machine scale set as well. The zonal properties of the prefix will be passed to the Virtual Machine instance IPs, though they will not be shown in the output. To view the public IP addresses assigned to the Virtual Machine Scale Sets Virtual Machine instances use the **az vmss list-instance-public-ips --resource-group `ResourceGroupName` --name `VirtualMachineScaleSetName`** CLI command.
 * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
 * @property loadBalancerInboundNatRulesIds A list of NAT Rule ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
 * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
 * @property name The Name which should be used for this IP Configuration.
 * @property primary Is this the Primary IP Configuration for this Network Interface? Defaults to `false`.
 * > **Note:** One `ip_configuration` block must be marked as Primary for each Network Interface.
 * @property publicIpAddresses A `public_ip_address` block as defined below.
 * @property subnetId The ID of the Subnet which this IP Configuration should be connected to.
 * > `subnet_id` is required if `version` is set to `IPv4`.
 * @property version The Internet Protocol Version which should be used for this IP Configuration. Possible values are `IPv4` and `IPv6`. Defaults to `IPv4`.
 */
public data class LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs(
    public val applicationGatewayBackendAddressPoolIds: Output>? = null,
    public val applicationSecurityGroupIds: Output>? = null,
    public val loadBalancerBackendAddressPoolIds: Output>? = null,
    public val loadBalancerInboundNatRulesIds: Output>? = null,
    public val name: Output,
    public val primary: Output? = null,
    public val publicIpAddresses: Output>? =
        null,
    public val subnetId: Output? = null,
    public val version: Output? = null,
) :
    ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.compute.inputs.LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs =
        com.pulumi.azure.compute.inputs.LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs.builder()
            .applicationGatewayBackendAddressPoolIds(
                applicationGatewayBackendAddressPoolIds?.applyValue({ args0 ->
                    args0.map({ args0 -> args0 })
                }),
            )
            .applicationSecurityGroupIds(
                applicationSecurityGroupIds?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0
                    })
                }),
            )
            .loadBalancerBackendAddressPoolIds(
                loadBalancerBackendAddressPoolIds?.applyValue({ args0 ->
                    args0.map({ args0 -> args0 })
                }),
            )
            .loadBalancerInboundNatRulesIds(
                loadBalancerInboundNatRulesIds?.applyValue({ args0 ->
                    args0.map({ args0 -> args0 })
                }),
            )
            .name(name.applyValue({ args0 -> args0 }))
            .primary(primary?.applyValue({ args0 -> args0 }))
            .publicIpAddresses(
                publicIpAddresses?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .subnetId(subnetId?.applyValue({ args0 -> args0 }))
            .version(version?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs].
 */
@PulumiTagMarker
public class LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgsBuilder internal constructor() {
    private var applicationGatewayBackendAddressPoolIds: Output>? = null

    private var applicationSecurityGroupIds: Output>? = null

    private var loadBalancerBackendAddressPoolIds: Output>? = null

    private var loadBalancerInboundNatRulesIds: Output>? = null

    private var name: Output? = null

    private var primary: Output? = null

    private var publicIpAddresses:
        Output>? =
        null

    private var subnetId: Output? = null

    private var version: Output? = null

    /**
     * @param value A list of Backend Address Pools ID's from a Application Gateway which this Virtual Machine Scale Set should be connected to.
     */
    @JvmName("ayweyamyihsyjhty")
    public suspend fun applicationGatewayBackendAddressPoolIds(`value`: Output>) {
        this.applicationGatewayBackendAddressPoolIds = value
    }

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

    /**
     * @param values A list of Backend Address Pools ID's from a Application Gateway which this Virtual Machine Scale Set should be connected to.
     */
    @JvmName("xewatffatystcvxg")
    public suspend fun applicationGatewayBackendAddressPoolIds(values: List>) {
        this.applicationGatewayBackendAddressPoolIds = Output.all(values)
    }

    /**
     * @param value A list of Application Security Group ID's which this Virtual Machine Scale Set should be connected to.
     */
    @JvmName("fqinydvveedstgkv")
    public suspend fun applicationSecurityGroupIds(`value`: Output>) {
        this.applicationSecurityGroupIds = value
    }

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

    /**
     * @param values A list of Application Security Group ID's which this Virtual Machine Scale Set should be connected to.
     */
    @JvmName("agqwjgpnmedxspra")
    public suspend fun applicationSecurityGroupIds(values: List>) {
        this.applicationSecurityGroupIds = Output.all(values)
    }

    /**
     * @param value A list of Backend Address Pools ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
     * > **Note:**  When the Virtual Machine Scale Set is configured to have public IPs per instance are created with a load balancer, the SKU of the Virtual Machine instance IPs is determined by the SKU of the Virtual Machine Scale Sets Load Balancer (e.g. `Basic` or `Standard`). Alternatively, you may use the `public_ip_prefix_id` field to generate instance-level IPs in a virtual machine scale set as well. The zonal properties of the prefix will be passed to the Virtual Machine instance IPs, though they will not be shown in the output. To view the public IP addresses assigned to the Virtual Machine Scale Sets Virtual Machine instances use the **az vmss list-instance-public-ips --resource-group `ResourceGroupName` --name `VirtualMachineScaleSetName`** CLI command.
     * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
     */
    @JvmName("iaxtguncbisowlvb")
    public suspend fun loadBalancerBackendAddressPoolIds(`value`: Output>) {
        this.loadBalancerBackendAddressPoolIds = value
    }

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

    /**
     * @param values A list of Backend Address Pools ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
     * > **Note:**  When the Virtual Machine Scale Set is configured to have public IPs per instance are created with a load balancer, the SKU of the Virtual Machine instance IPs is determined by the SKU of the Virtual Machine Scale Sets Load Balancer (e.g. `Basic` or `Standard`). Alternatively, you may use the `public_ip_prefix_id` field to generate instance-level IPs in a virtual machine scale set as well. The zonal properties of the prefix will be passed to the Virtual Machine instance IPs, though they will not be shown in the output. To view the public IP addresses assigned to the Virtual Machine Scale Sets Virtual Machine instances use the **az vmss list-instance-public-ips --resource-group `ResourceGroupName` --name `VirtualMachineScaleSetName`** CLI command.
     * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
     */
    @JvmName("dhwvgwmiwlfinsmg")
    public suspend fun loadBalancerBackendAddressPoolIds(values: List>) {
        this.loadBalancerBackendAddressPoolIds = Output.all(values)
    }

    /**
     * @param value A list of NAT Rule ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
     * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
     */
    @JvmName("eyqjmfcsuvvwmkvj")
    public suspend fun loadBalancerInboundNatRulesIds(`value`: Output>) {
        this.loadBalancerInboundNatRulesIds = value
    }

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

    /**
     * @param values A list of NAT Rule ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
     * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
     */
    @JvmName("kdkxlvxyyifqsqrp")
    public suspend fun loadBalancerInboundNatRulesIds(values: List>) {
        this.loadBalancerInboundNatRulesIds = Output.all(values)
    }

    /**
     * @param value The Name which should be used for this IP Configuration.
     */
    @JvmName("kdyviwhbslgjxvll")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value Is this the Primary IP Configuration for this Network Interface? Defaults to `false`.
     * > **Note:** One `ip_configuration` block must be marked as Primary for each Network Interface.
     */
    @JvmName("tbeblerxwjpdxqdc")
    public suspend fun primary(`value`: Output) {
        this.primary = value
    }

    /**
     * @param value A `public_ip_address` block as defined below.
     */
    @JvmName("qsvrwpnkcpkgskuw")
    public suspend fun publicIpAddresses(`value`: Output>) {
        this.publicIpAddresses = value
    }

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

    /**
     * @param values A `public_ip_address` block as defined below.
     */
    @JvmName("ssmcuognhtkleupf")
    public suspend fun publicIpAddresses(values: List>) {
        this.publicIpAddresses = Output.all(values)
    }

    /**
     * @param value The ID of the Subnet which this IP Configuration should be connected to.
     * > `subnet_id` is required if `version` is set to `IPv4`.
     */
    @JvmName("lqlggeilebujiqfv")
    public suspend fun subnetId(`value`: Output) {
        this.subnetId = value
    }

    /**
     * @param value The Internet Protocol Version which should be used for this IP Configuration. Possible values are `IPv4` and `IPv6`. Defaults to `IPv4`.
     */
    @JvmName("yxlumxqowpifpsqx")
    public suspend fun version(`value`: Output) {
        this.version = value
    }

    /**
     * @param value A list of Backend Address Pools ID's from a Application Gateway which this Virtual Machine Scale Set should be connected to.
     */
    @JvmName("apprvqjcslogwnao")
    public suspend fun applicationGatewayBackendAddressPoolIds(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.applicationGatewayBackendAddressPoolIds = mapped
    }

    /**
     * @param values A list of Backend Address Pools ID's from a Application Gateway which this Virtual Machine Scale Set should be connected to.
     */
    @JvmName("mwtkgteotpcpiofm")
    public suspend fun applicationGatewayBackendAddressPoolIds(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.applicationGatewayBackendAddressPoolIds = mapped
    }

    /**
     * @param value A list of Application Security Group ID's which this Virtual Machine Scale Set should be connected to.
     */
    @JvmName("onltlbkhryomtckd")
    public suspend fun applicationSecurityGroupIds(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.applicationSecurityGroupIds = mapped
    }

    /**
     * @param values A list of Application Security Group ID's which this Virtual Machine Scale Set should be connected to.
     */
    @JvmName("orldcgpgpvjiefti")
    public suspend fun applicationSecurityGroupIds(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.applicationSecurityGroupIds = mapped
    }

    /**
     * @param value A list of Backend Address Pools ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
     * > **Note:**  When the Virtual Machine Scale Set is configured to have public IPs per instance are created with a load balancer, the SKU of the Virtual Machine instance IPs is determined by the SKU of the Virtual Machine Scale Sets Load Balancer (e.g. `Basic` or `Standard`). Alternatively, you may use the `public_ip_prefix_id` field to generate instance-level IPs in a virtual machine scale set as well. The zonal properties of the prefix will be passed to the Virtual Machine instance IPs, though they will not be shown in the output. To view the public IP addresses assigned to the Virtual Machine Scale Sets Virtual Machine instances use the **az vmss list-instance-public-ips --resource-group `ResourceGroupName` --name `VirtualMachineScaleSetName`** CLI command.
     * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
     */
    @JvmName("xtdwjphhjjphoarj")
    public suspend fun loadBalancerBackendAddressPoolIds(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.loadBalancerBackendAddressPoolIds = mapped
    }

    /**
     * @param values A list of Backend Address Pools ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
     * > **Note:**  When the Virtual Machine Scale Set is configured to have public IPs per instance are created with a load balancer, the SKU of the Virtual Machine instance IPs is determined by the SKU of the Virtual Machine Scale Sets Load Balancer (e.g. `Basic` or `Standard`). Alternatively, you may use the `public_ip_prefix_id` field to generate instance-level IPs in a virtual machine scale set as well. The zonal properties of the prefix will be passed to the Virtual Machine instance IPs, though they will not be shown in the output. To view the public IP addresses assigned to the Virtual Machine Scale Sets Virtual Machine instances use the **az vmss list-instance-public-ips --resource-group `ResourceGroupName` --name `VirtualMachineScaleSetName`** CLI command.
     * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
     */
    @JvmName("wvlhdnsmkorodyjr")
    public suspend fun loadBalancerBackendAddressPoolIds(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.loadBalancerBackendAddressPoolIds = mapped
    }

    /**
     * @param value A list of NAT Rule ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
     * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
     */
    @JvmName("tfbhjsaknyyweyce")
    public suspend fun loadBalancerInboundNatRulesIds(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.loadBalancerInboundNatRulesIds = mapped
    }

    /**
     * @param values A list of NAT Rule ID's from a Load Balancer which this Virtual Machine Scale Set should be connected to.
     * > **Note:** When using this field you'll also need to configure a Rule for the Load Balancer, and use a `depends_on` between this resource and the Load Balancer Rule.
     */
    @JvmName("kylfkqkbatocxnof")
    public suspend fun loadBalancerInboundNatRulesIds(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.loadBalancerInboundNatRulesIds = mapped
    }

    /**
     * @param value The Name which should be used for this IP Configuration.
     */
    @JvmName("olffgufaxsejjajg")
    public suspend fun name(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value Is this the Primary IP Configuration for this Network Interface? Defaults to `false`.
     * > **Note:** One `ip_configuration` block must be marked as Primary for each Network Interface.
     */
    @JvmName("npukitybljnrqpif")
    public suspend fun primary(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.primary = mapped
    }

    /**
     * @param value A `public_ip_address` block as defined below.
     */
    @JvmName("jqgexcrnmbhceivx")
    public suspend fun publicIpAddresses(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.publicIpAddresses = mapped
    }

    /**
     * @param argument A `public_ip_address` block as defined below.
     */
    @JvmName("hloopapylatytkww")
    public suspend fun publicIpAddresses(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationPublicIpAddressArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.publicIpAddresses = mapped
    }

    /**
     * @param argument A `public_ip_address` block as defined below.
     */
    @JvmName("tdicvmsjgitxwhcx")
    public suspend fun publicIpAddresses(vararg argument: suspend LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationPublicIpAddressArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationPublicIpAddressArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.publicIpAddresses = mapped
    }

    /**
     * @param argument A `public_ip_address` block as defined below.
     */
    @JvmName("gvgrthvlfkagiphv")
    public suspend fun publicIpAddresses(argument: suspend LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationPublicIpAddressArgsBuilder.() -> Unit) {
        val toBeMapped =
            listOf(
                LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationPublicIpAddressArgsBuilder().applySuspend
                    { argument() }.build(),
            )
        val mapped = of(toBeMapped)
        this.publicIpAddresses = mapped
    }

    /**
     * @param values A `public_ip_address` block as defined below.
     */
    @JvmName("bcjbnqriiifchoad")
    public suspend fun publicIpAddresses(vararg values: LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationPublicIpAddressArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.publicIpAddresses = mapped
    }

    /**
     * @param value The ID of the Subnet which this IP Configuration should be connected to.
     * > `subnet_id` is required if `version` is set to `IPv4`.
     */
    @JvmName("dtviukhaefakmxxa")
    public suspend fun subnetId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.subnetId = mapped
    }

    /**
     * @param value The Internet Protocol Version which should be used for this IP Configuration. Possible values are `IPv4` and `IPv6`. Defaults to `IPv4`.
     */
    @JvmName("labjeurpkaxxtbdh")
    public suspend fun version(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.version = mapped
    }

    internal fun build(): LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs =
        LinuxVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs(
            applicationGatewayBackendAddressPoolIds = applicationGatewayBackendAddressPoolIds,
            applicationSecurityGroupIds = applicationSecurityGroupIds,
            loadBalancerBackendAddressPoolIds = loadBalancerBackendAddressPoolIds,
            loadBalancerInboundNatRulesIds = loadBalancerInboundNatRulesIds,
            name = name ?: throw PulumiNullFieldException("name"),
            primary = primary,
            publicIpAddresses = publicIpAddresses,
            subnetId = subnetId,
            version = version,
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy