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

com.pulumi.gcp.container.kotlin.inputs.AwsNodePoolConfigArgs.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: 8.12.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.container.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.container.inputs.AwsNodePoolConfigArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
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 autoscalingMetricsCollection Optional. Configuration related to CloudWatch metrics collection on the Auto Scaling group of the node pool. When unspecified, metrics collection is disabled.
 * @property configEncryption The ARN of the AWS KMS key used to encrypt node pool configuration.
 * @property iamInstanceProfile The name of the AWS IAM role assigned to nodes in the pool.
 * @property imageType The OS image type to use on node pool instances.
 * @property instancePlacement Details of placement information for an instance.
 * @property instanceType Optional. The AWS instance type. When unspecified, it defaults to `m5.large`.
 * @property labels Optional. The initial labels assigned to nodes of this node pool. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
 * @property proxyConfig Proxy configuration for outbound HTTP(S) traffic.
 * @property rootVolume Optional. Template for the root volume provisioned for node pool nodes. Volumes will be provisioned in the availability zone assigned to the node pool subnet. When unspecified, it defaults to 32 GiB with the GP2 volume type.
 * @property securityGroupIds Optional. The IDs of additional security groups to add to nodes in this pool. The manager will automatically create security groups with minimum rules needed for a functioning cluster.
 * @property spotConfig Optional. When specified, the node pool will provision Spot instances from the set of spot_config.instance_types. This field is mutually exclusive with `instance_type`
 * @property sshConfig Optional. The SSH configuration.
 * @property tags Optional. Key/value metadata to assign to each underlying AWS resource. Specify at most 50 pairs containing alphanumerics, spaces, and symbols (.+-=_:@/). Keys can be up to 127 Unicode characters. Values can be up to 255 Unicode characters.
 * @property taints Optional. The initial taints assigned to nodes of this node pool.
 */
public data class AwsNodePoolConfigArgs(
    public val autoscalingMetricsCollection: Output? = null,
    public val configEncryption: Output,
    public val iamInstanceProfile: Output,
    public val imageType: Output? = null,
    public val instancePlacement: Output? = null,
    public val instanceType: Output? = null,
    public val labels: Output>? = null,
    public val proxyConfig: Output? = null,
    public val rootVolume: Output? = null,
    public val securityGroupIds: Output>? = null,
    public val spotConfig: Output? = null,
    public val sshConfig: Output? = null,
    public val tags: Output>? = null,
    public val taints: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.container.inputs.AwsNodePoolConfigArgs =
        com.pulumi.gcp.container.inputs.AwsNodePoolConfigArgs.builder()
            .autoscalingMetricsCollection(
                autoscalingMetricsCollection?.applyValue({ args0 ->
                    args0.let({ args0 -> args0.toJava() })
                }),
            )
            .configEncryption(configEncryption.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .iamInstanceProfile(iamInstanceProfile.applyValue({ args0 -> args0 }))
            .imageType(imageType?.applyValue({ args0 -> args0 }))
            .instancePlacement(instancePlacement?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .instanceType(instanceType?.applyValue({ args0 -> args0 }))
            .labels(labels?.applyValue({ args0 -> args0.map({ args0 -> args0.key.to(args0.value) }).toMap() }))
            .proxyConfig(proxyConfig?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .rootVolume(rootVolume?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .securityGroupIds(securityGroupIds?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .spotConfig(spotConfig?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .sshConfig(sshConfig?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .tags(tags?.applyValue({ args0 -> args0.map({ args0 -> args0.key.to(args0.value) }).toMap() }))
            .taints(
                taints?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

/**
 * Builder for [AwsNodePoolConfigArgs].
 */
@PulumiTagMarker
public class AwsNodePoolConfigArgsBuilder internal constructor() {
    private var autoscalingMetricsCollection:
        Output? = null

    private var configEncryption: Output? = null

    private var iamInstanceProfile: Output? = null

    private var imageType: Output? = null

    private var instancePlacement: Output? = null

    private var instanceType: Output? = null

    private var labels: Output>? = null

    private var proxyConfig: Output? = null

    private var rootVolume: Output? = null

    private var securityGroupIds: Output>? = null

    private var spotConfig: Output? = null

    private var sshConfig: Output? = null

    private var tags: Output>? = null

    private var taints: Output>? = null

    /**
     * @param value Optional. Configuration related to CloudWatch metrics collection on the Auto Scaling group of the node pool. When unspecified, metrics collection is disabled.
     */
    @JvmName("tguwyspnyvesrbws")
    public suspend fun autoscalingMetricsCollection(`value`: Output) {
        this.autoscalingMetricsCollection = value
    }

    /**
     * @param value The ARN of the AWS KMS key used to encrypt node pool configuration.
     */
    @JvmName("eownjupotevkmqea")
    public suspend fun configEncryption(`value`: Output) {
        this.configEncryption = value
    }

    /**
     * @param value The name of the AWS IAM role assigned to nodes in the pool.
     */
    @JvmName("thypmbfgjxapxsye")
    public suspend fun iamInstanceProfile(`value`: Output) {
        this.iamInstanceProfile = value
    }

    /**
     * @param value The OS image type to use on node pool instances.
     */
    @JvmName("jqydpjbhrwfaeowl")
    public suspend fun imageType(`value`: Output) {
        this.imageType = value
    }

    /**
     * @param value Details of placement information for an instance.
     */
    @JvmName("truqsbsbeetcjjii")
    public suspend fun instancePlacement(`value`: Output) {
        this.instancePlacement = value
    }

    /**
     * @param value Optional. The AWS instance type. When unspecified, it defaults to `m5.large`.
     */
    @JvmName("byeiqycfixmsixmi")
    public suspend fun instanceType(`value`: Output) {
        this.instanceType = value
    }

    /**
     * @param value Optional. The initial labels assigned to nodes of this node pool. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
     */
    @JvmName("jldsjfrxrxgkkukw")
    public suspend fun labels(`value`: Output>) {
        this.labels = value
    }

    /**
     * @param value Proxy configuration for outbound HTTP(S) traffic.
     */
    @JvmName("akgixwvknxqglkud")
    public suspend fun proxyConfig(`value`: Output) {
        this.proxyConfig = value
    }

    /**
     * @param value Optional. Template for the root volume provisioned for node pool nodes. Volumes will be provisioned in the availability zone assigned to the node pool subnet. When unspecified, it defaults to 32 GiB with the GP2 volume type.
     */
    @JvmName("ybacmuvmfgycifxv")
    public suspend fun rootVolume(`value`: Output) {
        this.rootVolume = value
    }

    /**
     * @param value Optional. The IDs of additional security groups to add to nodes in this pool. The manager will automatically create security groups with minimum rules needed for a functioning cluster.
     */
    @JvmName("chuayoouvbcmvkie")
    public suspend fun securityGroupIds(`value`: Output>) {
        this.securityGroupIds = value
    }

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

    /**
     * @param values Optional. The IDs of additional security groups to add to nodes in this pool. The manager will automatically create security groups with minimum rules needed for a functioning cluster.
     */
    @JvmName("ljranmupjihypyts")
    public suspend fun securityGroupIds(values: List>) {
        this.securityGroupIds = Output.all(values)
    }

    /**
     * @param value Optional. When specified, the node pool will provision Spot instances from the set of spot_config.instance_types. This field is mutually exclusive with `instance_type`
     */
    @JvmName("qnomdgxnfuyirdmn")
    public suspend fun spotConfig(`value`: Output) {
        this.spotConfig = value
    }

    /**
     * @param value Optional. The SSH configuration.
     */
    @JvmName("drplqxctlybeuwxu")
    public suspend fun sshConfig(`value`: Output) {
        this.sshConfig = value
    }

    /**
     * @param value Optional. Key/value metadata to assign to each underlying AWS resource. Specify at most 50 pairs containing alphanumerics, spaces, and symbols (.+-=_:@/). Keys can be up to 127 Unicode characters. Values can be up to 255 Unicode characters.
     */
    @JvmName("btwhuxebbfqiapiu")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value Optional. The initial taints assigned to nodes of this node pool.
     */
    @JvmName("dsbhqpieetuqiqxh")
    public suspend fun taints(`value`: Output>) {
        this.taints = value
    }

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

    /**
     * @param values Optional. The initial taints assigned to nodes of this node pool.
     */
    @JvmName("kemkrwwbhfybxgef")
    public suspend fun taints(values: List>) {
        this.taints = Output.all(values)
    }

    /**
     * @param value Optional. Configuration related to CloudWatch metrics collection on the Auto Scaling group of the node pool. When unspecified, metrics collection is disabled.
     */
    @JvmName("mkmejpietgndfxuf")
    public suspend fun autoscalingMetricsCollection(`value`: AwsNodePoolConfigAutoscalingMetricsCollectionArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.autoscalingMetricsCollection = mapped
    }

    /**
     * @param argument Optional. Configuration related to CloudWatch metrics collection on the Auto Scaling group of the node pool. When unspecified, metrics collection is disabled.
     */
    @JvmName("nikrsfhhxbiylgoe")
    public suspend fun autoscalingMetricsCollection(argument: suspend AwsNodePoolConfigAutoscalingMetricsCollectionArgsBuilder.() -> Unit) {
        val toBeMapped = AwsNodePoolConfigAutoscalingMetricsCollectionArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.autoscalingMetricsCollection = mapped
    }

    /**
     * @param value The ARN of the AWS KMS key used to encrypt node pool configuration.
     */
    @JvmName("enhcsektmuxkbtgx")
    public suspend fun configEncryption(`value`: AwsNodePoolConfigConfigEncryptionArgs) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.configEncryption = mapped
    }

    /**
     * @param argument The ARN of the AWS KMS key used to encrypt node pool configuration.
     */
    @JvmName("tlaedoknvcjmhryu")
    public suspend fun configEncryption(argument: suspend AwsNodePoolConfigConfigEncryptionArgsBuilder.() -> Unit) {
        val toBeMapped = AwsNodePoolConfigConfigEncryptionArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.configEncryption = mapped
    }

    /**
     * @param value The name of the AWS IAM role assigned to nodes in the pool.
     */
    @JvmName("wxehhxpyhkewfkav")
    public suspend fun iamInstanceProfile(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.iamInstanceProfile = mapped
    }

    /**
     * @param value The OS image type to use on node pool instances.
     */
    @JvmName("ctrwwwirukekwlvn")
    public suspend fun imageType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.imageType = mapped
    }

    /**
     * @param value Details of placement information for an instance.
     */
    @JvmName("roleirunnycjhidf")
    public suspend fun instancePlacement(`value`: AwsNodePoolConfigInstancePlacementArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.instancePlacement = mapped
    }

    /**
     * @param argument Details of placement information for an instance.
     */
    @JvmName("andxmhfuuiahbqnx")
    public suspend fun instancePlacement(argument: suspend AwsNodePoolConfigInstancePlacementArgsBuilder.() -> Unit) {
        val toBeMapped = AwsNodePoolConfigInstancePlacementArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.instancePlacement = mapped
    }

    /**
     * @param value Optional. The AWS instance type. When unspecified, it defaults to `m5.large`.
     */
    @JvmName("moceyclrftphtmmj")
    public suspend fun instanceType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.instanceType = mapped
    }

    /**
     * @param value Optional. The initial labels assigned to nodes of this node pool. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
     */
    @JvmName("iprakjvqayjvcair")
    public suspend fun labels(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.labels = mapped
    }

    /**
     * @param values Optional. The initial labels assigned to nodes of this node pool. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
     */
    @JvmName("ssanfbepkmkvwral")
    public fun labels(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.labels = mapped
    }

    /**
     * @param value Proxy configuration for outbound HTTP(S) traffic.
     */
    @JvmName("qkofvmtndpbahehs")
    public suspend fun proxyConfig(`value`: AwsNodePoolConfigProxyConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.proxyConfig = mapped
    }

    /**
     * @param argument Proxy configuration for outbound HTTP(S) traffic.
     */
    @JvmName("abttklykfrvromfs")
    public suspend fun proxyConfig(argument: suspend AwsNodePoolConfigProxyConfigArgsBuilder.() -> Unit) {
        val toBeMapped = AwsNodePoolConfigProxyConfigArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.proxyConfig = mapped
    }

    /**
     * @param value Optional. Template for the root volume provisioned for node pool nodes. Volumes will be provisioned in the availability zone assigned to the node pool subnet. When unspecified, it defaults to 32 GiB with the GP2 volume type.
     */
    @JvmName("kgpvtrgtdqnprugd")
    public suspend fun rootVolume(`value`: AwsNodePoolConfigRootVolumeArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.rootVolume = mapped
    }

    /**
     * @param argument Optional. Template for the root volume provisioned for node pool nodes. Volumes will be provisioned in the availability zone assigned to the node pool subnet. When unspecified, it defaults to 32 GiB with the GP2 volume type.
     */
    @JvmName("pxvxgvftggrsgste")
    public suspend fun rootVolume(argument: suspend AwsNodePoolConfigRootVolumeArgsBuilder.() -> Unit) {
        val toBeMapped = AwsNodePoolConfigRootVolumeArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.rootVolume = mapped
    }

    /**
     * @param value Optional. The IDs of additional security groups to add to nodes in this pool. The manager will automatically create security groups with minimum rules needed for a functioning cluster.
     */
    @JvmName("mntjbrblmkxtqglc")
    public suspend fun securityGroupIds(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.securityGroupIds = mapped
    }

    /**
     * @param values Optional. The IDs of additional security groups to add to nodes in this pool. The manager will automatically create security groups with minimum rules needed for a functioning cluster.
     */
    @JvmName("nimfbicwcunbitci")
    public suspend fun securityGroupIds(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.securityGroupIds = mapped
    }

    /**
     * @param value Optional. When specified, the node pool will provision Spot instances from the set of spot_config.instance_types. This field is mutually exclusive with `instance_type`
     */
    @JvmName("eifmpetmlrxjhwjs")
    public suspend fun spotConfig(`value`: AwsNodePoolConfigSpotConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.spotConfig = mapped
    }

    /**
     * @param argument Optional. When specified, the node pool will provision Spot instances from the set of spot_config.instance_types. This field is mutually exclusive with `instance_type`
     */
    @JvmName("xfsvcixsvxnlhkha")
    public suspend fun spotConfig(argument: suspend AwsNodePoolConfigSpotConfigArgsBuilder.() -> Unit) {
        val toBeMapped = AwsNodePoolConfigSpotConfigArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.spotConfig = mapped
    }

    /**
     * @param value Optional. The SSH configuration.
     */
    @JvmName("jchxelcblcsxhjpy")
    public suspend fun sshConfig(`value`: AwsNodePoolConfigSshConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sshConfig = mapped
    }

    /**
     * @param argument Optional. The SSH configuration.
     */
    @JvmName("sqwmlqrojiehthms")
    public suspend fun sshConfig(argument: suspend AwsNodePoolConfigSshConfigArgsBuilder.() -> Unit) {
        val toBeMapped = AwsNodePoolConfigSshConfigArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.sshConfig = mapped
    }

    /**
     * @param value Optional. Key/value metadata to assign to each underlying AWS resource. Specify at most 50 pairs containing alphanumerics, spaces, and symbols (.+-=_:@/). Keys can be up to 127 Unicode characters. Values can be up to 255 Unicode characters.
     */
    @JvmName("ljehtpyfsnjfsadu")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values Optional. Key/value metadata to assign to each underlying AWS resource. Specify at most 50 pairs containing alphanumerics, spaces, and symbols (.+-=_:@/). Keys can be up to 127 Unicode characters. Values can be up to 255 Unicode characters.
     */
    @JvmName("lexpxyoqhfvfiayi")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param value Optional. The initial taints assigned to nodes of this node pool.
     */
    @JvmName("qepihqbillnkjvib")
    public suspend fun taints(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.taints = mapped
    }

    /**
     * @param argument Optional. The initial taints assigned to nodes of this node pool.
     */
    @JvmName("xndejoxfxjsmnokj")
    public suspend fun taints(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            AwsNodePoolConfigTaintArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.taints = mapped
    }

    /**
     * @param argument Optional. The initial taints assigned to nodes of this node pool.
     */
    @JvmName("icqpfjielqogbuxk")
    public suspend fun taints(vararg argument: suspend AwsNodePoolConfigTaintArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            AwsNodePoolConfigTaintArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.taints = mapped
    }

    /**
     * @param argument Optional. The initial taints assigned to nodes of this node pool.
     */
    @JvmName("cgmoccodpkuxtltr")
    public suspend fun taints(argument: suspend AwsNodePoolConfigTaintArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(AwsNodePoolConfigTaintArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.taints = mapped
    }

    /**
     * @param values Optional. The initial taints assigned to nodes of this node pool.
     */
    @JvmName("mvwauybfqiawaoaj")
    public suspend fun taints(vararg values: AwsNodePoolConfigTaintArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.taints = mapped
    }

    internal fun build(): AwsNodePoolConfigArgs = AwsNodePoolConfigArgs(
        autoscalingMetricsCollection = autoscalingMetricsCollection,
        configEncryption = configEncryption ?: throw PulumiNullFieldException("configEncryption"),
        iamInstanceProfile = iamInstanceProfile ?: throw PulumiNullFieldException("iamInstanceProfile"),
        imageType = imageType,
        instancePlacement = instancePlacement,
        instanceType = instanceType,
        labels = labels,
        proxyConfig = proxyConfig,
        rootVolume = rootVolume,
        securityGroupIds = securityGroupIds,
        spotConfig = spotConfig,
        sshConfig = sshConfig,
        tags = tags,
        taints = taints,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy