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

com.pulumi.azure.batch.kotlin.inputs.PoolNetworkConfigurationEndpointConfigurationArgs.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.batch.kotlin.inputs

import com.pulumi.azure.batch.inputs.PoolNetworkConfigurationEndpointConfigurationArgs.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.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property backendPort The port number on the compute node. Acceptable values are between `1` and `65535` except for `29876`, `29877` as these are reserved. Changing this forces a new resource to be created.
 * @property frontendPortRange The range of external ports that will be used to provide inbound access to the backendPort on individual compute nodes in the format of `1000-1100`. Acceptable values range between `1` and `65534` except ports from `50000` to `55000` which are reserved by the Batch service. All ranges within a pool must be distinct and cannot overlap. Values must be a range of at least `100` nodes. Changing this forces a new resource to be created.
 * @property name The name of the endpoint. The name must be unique within a Batch pool, can contain letters, numbers, underscores, periods, and hyphens. Names must start with a letter or number, must end with a letter, number, or underscore, and cannot exceed 77 characters. Changing this forces a new resource to be created.
 * @property networkSecurityGroupRules A list of `network_security_group_rules` blocks as defined below that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is `25`. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. Set as documented in the network_security_group_rules block below. Changing this forces a new resource to be created.
 * @property protocol The protocol of the endpoint. Acceptable values are `TCP` and `UDP`. Changing this forces a new resource to be created.
 */
public data class PoolNetworkConfigurationEndpointConfigurationArgs(
    public val backendPort: Output,
    public val frontendPortRange: Output,
    public val name: Output,
    public val networkSecurityGroupRules: Output>? =
        null,
    public val protocol: Output,
) :
    ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.batch.inputs.PoolNetworkConfigurationEndpointConfigurationArgs =
        com.pulumi.azure.batch.inputs.PoolNetworkConfigurationEndpointConfigurationArgs.builder()
            .backendPort(backendPort.applyValue({ args0 -> args0 }))
            .frontendPortRange(frontendPortRange.applyValue({ args0 -> args0 }))
            .name(name.applyValue({ args0 -> args0 }))
            .networkSecurityGroupRules(
                networkSecurityGroupRules?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .protocol(protocol.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [PoolNetworkConfigurationEndpointConfigurationArgs].
 */
@PulumiTagMarker
public class PoolNetworkConfigurationEndpointConfigurationArgsBuilder internal constructor() {
    private var backendPort: Output? = null

    private var frontendPortRange: Output? = null

    private var name: Output? = null

    private var networkSecurityGroupRules:
        Output>? =
        null

    private var protocol: Output? = null

    /**
     * @param value The port number on the compute node. Acceptable values are between `1` and `65535` except for `29876`, `29877` as these are reserved. Changing this forces a new resource to be created.
     */
    @JvmName("ueckqstwbuoyccpg")
    public suspend fun backendPort(`value`: Output) {
        this.backendPort = value
    }

    /**
     * @param value The range of external ports that will be used to provide inbound access to the backendPort on individual compute nodes in the format of `1000-1100`. Acceptable values range between `1` and `65534` except ports from `50000` to `55000` which are reserved by the Batch service. All ranges within a pool must be distinct and cannot overlap. Values must be a range of at least `100` nodes. Changing this forces a new resource to be created.
     */
    @JvmName("pbbtnrdfhgkjktfd")
    public suspend fun frontendPortRange(`value`: Output) {
        this.frontendPortRange = value
    }

    /**
     * @param value The name of the endpoint. The name must be unique within a Batch pool, can contain letters, numbers, underscores, periods, and hyphens. Names must start with a letter or number, must end with a letter, number, or underscore, and cannot exceed 77 characters. Changing this forces a new resource to be created.
     */
    @JvmName("vlxwdjfeiooyisqd")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value A list of `network_security_group_rules` blocks as defined below that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is `25`. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. Set as documented in the network_security_group_rules block below. Changing this forces a new resource to be created.
     */
    @JvmName("juhqowwgtilktdug")
    public suspend fun networkSecurityGroupRules(`value`: Output>) {
        this.networkSecurityGroupRules = value
    }

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

    /**
     * @param values A list of `network_security_group_rules` blocks as defined below that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is `25`. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. Set as documented in the network_security_group_rules block below. Changing this forces a new resource to be created.
     */
    @JvmName("gicdqlnurvdalbqr")
    public suspend fun networkSecurityGroupRules(values: List>) {
        this.networkSecurityGroupRules = Output.all(values)
    }

    /**
     * @param value The protocol of the endpoint. Acceptable values are `TCP` and `UDP`. Changing this forces a new resource to be created.
     */
    @JvmName("jsdkuiullbbpbfue")
    public suspend fun protocol(`value`: Output) {
        this.protocol = value
    }

    /**
     * @param value The port number on the compute node. Acceptable values are between `1` and `65535` except for `29876`, `29877` as these are reserved. Changing this forces a new resource to be created.
     */
    @JvmName("jkylspmntmbnfbiq")
    public suspend fun backendPort(`value`: Int) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.backendPort = mapped
    }

    /**
     * @param value The range of external ports that will be used to provide inbound access to the backendPort on individual compute nodes in the format of `1000-1100`. Acceptable values range between `1` and `65534` except ports from `50000` to `55000` which are reserved by the Batch service. All ranges within a pool must be distinct and cannot overlap. Values must be a range of at least `100` nodes. Changing this forces a new resource to be created.
     */
    @JvmName("lfbnmxhaqevqsknm")
    public suspend fun frontendPortRange(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.frontendPortRange = mapped
    }

    /**
     * @param value The name of the endpoint. The name must be unique within a Batch pool, can contain letters, numbers, underscores, periods, and hyphens. Names must start with a letter or number, must end with a letter, number, or underscore, and cannot exceed 77 characters. Changing this forces a new resource to be created.
     */
    @JvmName("avrtcvlkttxbtvdd")
    public suspend fun name(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value A list of `network_security_group_rules` blocks as defined below that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is `25`. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. Set as documented in the network_security_group_rules block below. Changing this forces a new resource to be created.
     */
    @JvmName("tnsraocwaudnffos")
    public suspend fun networkSecurityGroupRules(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.networkSecurityGroupRules = mapped
    }

    /**
     * @param argument A list of `network_security_group_rules` blocks as defined below that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is `25`. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. Set as documented in the network_security_group_rules block below. Changing this forces a new resource to be created.
     */
    @JvmName("ugkfjfvlqycwfhxn")
    public suspend fun networkSecurityGroupRules(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            PoolNetworkConfigurationEndpointConfigurationNetworkSecurityGroupRuleArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.networkSecurityGroupRules = mapped
    }

    /**
     * @param argument A list of `network_security_group_rules` blocks as defined below that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is `25`. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. Set as documented in the network_security_group_rules block below. Changing this forces a new resource to be created.
     */
    @JvmName("cymookchrhkqoxcv")
    public suspend fun networkSecurityGroupRules(vararg argument: suspend PoolNetworkConfigurationEndpointConfigurationNetworkSecurityGroupRuleArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            PoolNetworkConfigurationEndpointConfigurationNetworkSecurityGroupRuleArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.networkSecurityGroupRules = mapped
    }

    /**
     * @param argument A list of `network_security_group_rules` blocks as defined below that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is `25`. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. Set as documented in the network_security_group_rules block below. Changing this forces a new resource to be created.
     */
    @JvmName("kxbfxeweqymwlcap")
    public suspend fun networkSecurityGroupRules(argument: suspend PoolNetworkConfigurationEndpointConfigurationNetworkSecurityGroupRuleArgsBuilder.() -> Unit) {
        val toBeMapped =
            listOf(
                PoolNetworkConfigurationEndpointConfigurationNetworkSecurityGroupRuleArgsBuilder().applySuspend
                    { argument() }.build(),
            )
        val mapped = of(toBeMapped)
        this.networkSecurityGroupRules = mapped
    }

    /**
     * @param values A list of `network_security_group_rules` blocks as defined below that will be applied to the endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is `25`. If no network security group rules are specified, a default rule will be created to allow inbound access to the specified backendPort. Set as documented in the network_security_group_rules block below. Changing this forces a new resource to be created.
     */
    @JvmName("kykgujppufimcola")
    public suspend fun networkSecurityGroupRules(vararg values: PoolNetworkConfigurationEndpointConfigurationNetworkSecurityGroupRuleArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.networkSecurityGroupRules = mapped
    }

    /**
     * @param value The protocol of the endpoint. Acceptable values are `TCP` and `UDP`. Changing this forces a new resource to be created.
     */
    @JvmName("hnbpsahfxunchkti")
    public suspend fun protocol(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.protocol = mapped
    }

    internal fun build(): PoolNetworkConfigurationEndpointConfigurationArgs =
        PoolNetworkConfigurationEndpointConfigurationArgs(
            backendPort = backendPort ?: throw PulumiNullFieldException("backendPort"),
            frontendPortRange = frontendPortRange ?: throw PulumiNullFieldException("frontendPortRange"),
            name = name ?: throw PulumiNullFieldException("name"),
            networkSecurityGroupRules = networkSecurityGroupRules,
            protocol = protocol ?: throw PulumiNullFieldException("protocol"),
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy