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

com.pulumi.awsnative.gamelift.kotlin.ContainerGroupDefinitionArgs.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.gamelift.kotlin

import com.pulumi.awsnative.gamelift.ContainerGroupDefinitionArgs.builder
import com.pulumi.awsnative.gamelift.kotlin.enums.ContainerGroupDefinitionOperatingSystem
import com.pulumi.awsnative.gamelift.kotlin.enums.ContainerGroupDefinitionSchedulingStrategy
import com.pulumi.awsnative.gamelift.kotlin.inputs.ContainerGroupDefinitionContainerDefinitionArgs
import com.pulumi.awsnative.gamelift.kotlin.inputs.ContainerGroupDefinitionContainerDefinitionArgsBuilder
import com.pulumi.awsnative.kotlin.inputs.TagArgs
import com.pulumi.awsnative.kotlin.inputs.TagArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * The AWS::GameLift::ContainerGroupDefinition resource creates an Amazon GameLift container group definition.
 * @property containerDefinitions A collection of container definitions that define the containers in this group.
 * @property name A descriptive label for the container group definition.
 * @property operatingSystem The operating system of the container group
 * @property schedulingStrategy Specifies whether the container group includes replica or daemon containers.
 * @property tags An array of key-value pairs to apply to this resource.
 * @property totalCpuLimit The maximum number of CPU units reserved for this container group. The value is expressed as an integer amount of CPU units. (1 vCPU is equal to 1024 CPU units.)
 * @property totalMemoryLimit The maximum amount of memory (in MiB) to allocate for this container group.
 */
public data class ContainerGroupDefinitionArgs(
    public val containerDefinitions: Output>? =
        null,
    public val name: Output? = null,
    public val operatingSystem: Output? = null,
    public val schedulingStrategy: Output? = null,
    public val tags: Output>? = null,
    public val totalCpuLimit: Output? = null,
    public val totalMemoryLimit: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.gamelift.ContainerGroupDefinitionArgs =
        com.pulumi.awsnative.gamelift.ContainerGroupDefinitionArgs.builder()
            .containerDefinitions(
                containerDefinitions?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .name(name?.applyValue({ args0 -> args0 }))
            .operatingSystem(operatingSystem?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .schedulingStrategy(
                schedulingStrategy?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .tags(tags?.applyValue({ args0 -> args0.map({ args0 -> args0.let({ args0 -> args0.toJava() }) }) }))
            .totalCpuLimit(totalCpuLimit?.applyValue({ args0 -> args0 }))
            .totalMemoryLimit(totalMemoryLimit?.applyValue({ args0 -> args0 })).build()
}

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

    private var name: Output? = null

    private var operatingSystem: Output? = null

    private var schedulingStrategy: Output? = null

    private var tags: Output>? = null

    private var totalCpuLimit: Output? = null

    private var totalMemoryLimit: Output? = null

    /**
     * @param value A collection of container definitions that define the containers in this group.
     */
    @JvmName("oqgecmqvjqftxmni")
    public suspend fun containerDefinitions(`value`: Output>) {
        this.containerDefinitions = value
    }

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

    /**
     * @param values A collection of container definitions that define the containers in this group.
     */
    @JvmName("pcaohyibrmtrhanm")
    public suspend fun containerDefinitions(values: List>) {
        this.containerDefinitions = Output.all(values)
    }

    /**
     * @param value A descriptive label for the container group definition.
     */
    @JvmName("igqykkwayayqaudq")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The operating system of the container group
     */
    @JvmName("djmqjwwclibnqfav")
    public suspend fun operatingSystem(`value`: Output) {
        this.operatingSystem = value
    }

    /**
     * @param value Specifies whether the container group includes replica or daemon containers.
     */
    @JvmName("vcghnlkeasxysryx")
    public suspend fun schedulingStrategy(`value`: Output) {
        this.schedulingStrategy = value
    }

    /**
     * @param value An array of key-value pairs to apply to this resource.
     */
    @JvmName("syveipjqffywinyo")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

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

    /**
     * @param values An array of key-value pairs to apply to this resource.
     */
    @JvmName("nlioballlwceifei")
    public suspend fun tags(values: List>) {
        this.tags = Output.all(values)
    }

    /**
     * @param value The maximum number of CPU units reserved for this container group. The value is expressed as an integer amount of CPU units. (1 vCPU is equal to 1024 CPU units.)
     */
    @JvmName("kotawjwkvvxwhwhm")
    public suspend fun totalCpuLimit(`value`: Output) {
        this.totalCpuLimit = value
    }

    /**
     * @param value The maximum amount of memory (in MiB) to allocate for this container group.
     */
    @JvmName("qwmcxoatvekgovrp")
    public suspend fun totalMemoryLimit(`value`: Output) {
        this.totalMemoryLimit = value
    }

    /**
     * @param value A collection of container definitions that define the containers in this group.
     */
    @JvmName("ybkwcaldppuwkcox")
    public suspend fun containerDefinitions(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.containerDefinitions = mapped
    }

    /**
     * @param argument A collection of container definitions that define the containers in this group.
     */
    @JvmName("vcsayiaxmgxabjoa")
    public suspend fun containerDefinitions(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ContainerGroupDefinitionContainerDefinitionArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.containerDefinitions = mapped
    }

    /**
     * @param argument A collection of container definitions that define the containers in this group.
     */
    @JvmName("vargxbbvufiuowxa")
    public suspend fun containerDefinitions(vararg argument: suspend ContainerGroupDefinitionContainerDefinitionArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ContainerGroupDefinitionContainerDefinitionArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.containerDefinitions = mapped
    }

    /**
     * @param argument A collection of container definitions that define the containers in this group.
     */
    @JvmName("ayxifiastupgtjvk")
    public suspend fun containerDefinitions(argument: suspend ContainerGroupDefinitionContainerDefinitionArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            ContainerGroupDefinitionContainerDefinitionArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.containerDefinitions = mapped
    }

    /**
     * @param values A collection of container definitions that define the containers in this group.
     */
    @JvmName("ssbdfhqxmhqeldil")
    public suspend fun containerDefinitions(vararg values: ContainerGroupDefinitionContainerDefinitionArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.containerDefinitions = mapped
    }

    /**
     * @param value A descriptive label for the container group definition.
     */
    @JvmName("bmuwpsdrtrclnmpg")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value The operating system of the container group
     */
    @JvmName("twjppjeobitrrwvb")
    public suspend fun operatingSystem(`value`: ContainerGroupDefinitionOperatingSystem?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.operatingSystem = mapped
    }

    /**
     * @param value Specifies whether the container group includes replica or daemon containers.
     */
    @JvmName("oklcvbxjnsreqdly")
    public suspend fun schedulingStrategy(`value`: ContainerGroupDefinitionSchedulingStrategy?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.schedulingStrategy = mapped
    }

    /**
     * @param value An array of key-value pairs to apply to this resource.
     */
    @JvmName("eltqtvgsmgbchbed")
    public suspend fun tags(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param argument An array of key-value pairs to apply to this resource.
     */
    @JvmName("hhrgdrkvumcspprp")
    public suspend fun tags(argument: List Unit>) {
        val toBeMapped = argument.toList().map { TagArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.tags = mapped
    }

    /**
     * @param argument An array of key-value pairs to apply to this resource.
     */
    @JvmName("aiskvovacjyntexa")
    public suspend fun tags(vararg argument: suspend TagArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map { TagArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.tags = mapped
    }

    /**
     * @param argument An array of key-value pairs to apply to this resource.
     */
    @JvmName("qvqbhoruxnqbmvmu")
    public suspend fun tags(argument: suspend TagArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(TagArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.tags = mapped
    }

    /**
     * @param values An array of key-value pairs to apply to this resource.
     */
    @JvmName("mnvfwwcwtvfrkqfu")
    public suspend fun tags(vararg values: TagArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param value The maximum number of CPU units reserved for this container group. The value is expressed as an integer amount of CPU units. (1 vCPU is equal to 1024 CPU units.)
     */
    @JvmName("ejdlkldkdgwhajel")
    public suspend fun totalCpuLimit(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.totalCpuLimit = mapped
    }

    /**
     * @param value The maximum amount of memory (in MiB) to allocate for this container group.
     */
    @JvmName("gjehdgcnercdfodo")
    public suspend fun totalMemoryLimit(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.totalMemoryLimit = mapped
    }

    internal fun build(): ContainerGroupDefinitionArgs = ContainerGroupDefinitionArgs(
        containerDefinitions = containerDefinitions,
        name = name,
        operatingSystem = operatingSystem,
        schedulingStrategy = schedulingStrategy,
        tags = tags,
        totalCpuLimit = totalCpuLimit,
        totalMemoryLimit = totalMemoryLimit,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy