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

com.pulumi.awsnative.pipes.kotlin.inputs.PipeEcsContainerOverrideArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.awsnative.pipes.kotlin.inputs

import com.pulumi.awsnative.pipes.inputs.PipeEcsContainerOverrideArgs.builder
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

/**
 *
 * @property command The command to send to the container that overrides the default command from the Docker image or the task definition. You must also specify a container name.
 * @property cpu The number of `cpu` units reserved for the container, instead of the default value from the task definition. You must also specify a container name.
 * @property environment The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
 * @property environmentFiles A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
 * @property memory The hard limit (in MiB) of memory to present to the container, instead of the default value from the task definition. If your container attempts to exceed the memory specified here, the container is killed. You must also specify a container name.
 * @property memoryReservation The soft limit (in MiB) of memory to reserve for the container, instead of the default value from the task definition. You must also specify a container name.
 * @property name The name of the container that receives the override. This parameter is required if any override is specified.
 * @property resourceRequirements The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
 */
public data class PipeEcsContainerOverrideArgs(
    public val command: Output>? = null,
    public val cpu: Output? = null,
    public val environment: Output>? = null,
    public val environmentFiles: Output>? = null,
    public val memory: Output? = null,
    public val memoryReservation: Output? = null,
    public val name: Output? = null,
    public val resourceRequirements: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.pipes.inputs.PipeEcsContainerOverrideArgs =
        com.pulumi.awsnative.pipes.inputs.PipeEcsContainerOverrideArgs.builder()
            .command(command?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .cpu(cpu?.applyValue({ args0 -> args0 }))
            .environment(
                environment?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .environmentFiles(
                environmentFiles?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .memory(memory?.applyValue({ args0 -> args0 }))
            .memoryReservation(memoryReservation?.applyValue({ args0 -> args0 }))
            .name(name?.applyValue({ args0 -> args0 }))
            .resourceRequirements(
                resourceRequirements?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            ).build()
}

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

    private var cpu: Output? = null

    private var environment: Output>? = null

    private var environmentFiles: Output>? = null

    private var memory: Output? = null

    private var memoryReservation: Output? = null

    private var name: Output? = null

    private var resourceRequirements: Output>? = null

    /**
     * @param value The command to send to the container that overrides the default command from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("pdvdpfapdvdcakyl")
    public suspend fun command(`value`: Output>) {
        this.command = value
    }

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

    /**
     * @param values The command to send to the container that overrides the default command from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("joavccvlchknhrim")
    public suspend fun command(values: List>) {
        this.command = Output.all(values)
    }

    /**
     * @param value The number of `cpu` units reserved for the container, instead of the default value from the task definition. You must also specify a container name.
     */
    @JvmName("xeqbalvbivoghucx")
    public suspend fun cpu(`value`: Output) {
        this.cpu = value
    }

    /**
     * @param value The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("jhttgxpmktffswxv")
    public suspend fun environment(`value`: Output>) {
        this.environment = value
    }

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

    /**
     * @param values The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("psybugyqnbrivfty")
    public suspend fun environment(values: List>) {
        this.environment = Output.all(values)
    }

    /**
     * @param value A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
     */
    @JvmName("ahnjusnsfyvpunsh")
    public suspend fun environmentFiles(`value`: Output>) {
        this.environmentFiles = value
    }

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

    /**
     * @param values A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
     */
    @JvmName("oedcyogahkaeqivt")
    public suspend fun environmentFiles(values: List>) {
        this.environmentFiles = Output.all(values)
    }

    /**
     * @param value The hard limit (in MiB) of memory to present to the container, instead of the default value from the task definition. If your container attempts to exceed the memory specified here, the container is killed. You must also specify a container name.
     */
    @JvmName("dsqdmseodisvceyd")
    public suspend fun memory(`value`: Output) {
        this.memory = value
    }

    /**
     * @param value The soft limit (in MiB) of memory to reserve for the container, instead of the default value from the task definition. You must also specify a container name.
     */
    @JvmName("ersuqgpmuisfohhh")
    public suspend fun memoryReservation(`value`: Output) {
        this.memoryReservation = value
    }

    /**
     * @param value The name of the container that receives the override. This parameter is required if any override is specified.
     */
    @JvmName("rnsmyifdrxpmvqfy")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
     */
    @JvmName("ltqckraomgnxhrhf")
    public suspend fun resourceRequirements(`value`: Output>) {
        this.resourceRequirements = value
    }

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

    /**
     * @param values The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
     */
    @JvmName("wmkufdyjpsinxcky")
    public suspend fun resourceRequirements(values: List>) {
        this.resourceRequirements = Output.all(values)
    }

    /**
     * @param value The command to send to the container that overrides the default command from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("bxuecedehvvctndm")
    public suspend fun command(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.command = mapped
    }

    /**
     * @param values The command to send to the container that overrides the default command from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("qbsnbotedjjiwicc")
    public suspend fun command(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.command = mapped
    }

    /**
     * @param value The number of `cpu` units reserved for the container, instead of the default value from the task definition. You must also specify a container name.
     */
    @JvmName("sfjkirnrhgtsswpj")
    public suspend fun cpu(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cpu = mapped
    }

    /**
     * @param value The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("vbgwliskxiqksdcn")
    public suspend fun environment(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.environment = mapped
    }

    /**
     * @param argument The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("xnqhnmuuqpphgiwf")
    public suspend fun environment(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            PipeEcsEnvironmentVariableArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.environment = mapped
    }

    /**
     * @param argument The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("eihgijkhwgyiondn")
    public suspend fun environment(vararg argument: suspend PipeEcsEnvironmentVariableArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            PipeEcsEnvironmentVariableArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.environment = mapped
    }

    /**
     * @param argument The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("dvpctsuabsxllwti")
    public suspend fun environment(argument: suspend PipeEcsEnvironmentVariableArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            PipeEcsEnvironmentVariableArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.environment = mapped
    }

    /**
     * @param values The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
     */
    @JvmName("lctwsbausceymqyv")
    public suspend fun environment(vararg values: PipeEcsEnvironmentVariableArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.environment = mapped
    }

    /**
     * @param value A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
     */
    @JvmName("mumxcygghfscmyns")
    public suspend fun environmentFiles(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.environmentFiles = mapped
    }

    /**
     * @param argument A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
     */
    @JvmName("dkiefskgfodqyjex")
    public suspend fun environmentFiles(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            PipeEcsEnvironmentFileArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.environmentFiles = mapped
    }

    /**
     * @param argument A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
     */
    @JvmName("taurhgabirkqtxsr")
    public suspend fun environmentFiles(vararg argument: suspend PipeEcsEnvironmentFileArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            PipeEcsEnvironmentFileArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.environmentFiles = mapped
    }

    /**
     * @param argument A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
     */
    @JvmName("qiobgvqjywyqatbq")
    public suspend fun environmentFiles(argument: suspend PipeEcsEnvironmentFileArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(PipeEcsEnvironmentFileArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.environmentFiles = mapped
    }

    /**
     * @param values A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
     */
    @JvmName("yqyengbygpbkwgxb")
    public suspend fun environmentFiles(vararg values: PipeEcsEnvironmentFileArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.environmentFiles = mapped
    }

    /**
     * @param value The hard limit (in MiB) of memory to present to the container, instead of the default value from the task definition. If your container attempts to exceed the memory specified here, the container is killed. You must also specify a container name.
     */
    @JvmName("owfudnmghljajnsh")
    public suspend fun memory(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.memory = mapped
    }

    /**
     * @param value The soft limit (in MiB) of memory to reserve for the container, instead of the default value from the task definition. You must also specify a container name.
     */
    @JvmName("jpinijuvkjlpcevm")
    public suspend fun memoryReservation(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.memoryReservation = mapped
    }

    /**
     * @param value The name of the container that receives the override. This parameter is required if any override is specified.
     */
    @JvmName("nejasuciabwlwxjs")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
     */
    @JvmName("vmnclnddnxvjkqce")
    public suspend fun resourceRequirements(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceRequirements = mapped
    }

    /**
     * @param argument The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
     */
    @JvmName("prwqsxnkekgbjpvk")
    public suspend fun resourceRequirements(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            PipeEcsResourceRequirementArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.resourceRequirements = mapped
    }

    /**
     * @param argument The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
     */
    @JvmName("vcqskbheaygtayhk")
    public suspend fun resourceRequirements(vararg argument: suspend PipeEcsResourceRequirementArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            PipeEcsResourceRequirementArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.resourceRequirements = mapped
    }

    /**
     * @param argument The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
     */
    @JvmName("emnkxlgfomqdfafl")
    public suspend fun resourceRequirements(argument: suspend PipeEcsResourceRequirementArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            PipeEcsResourceRequirementArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.resourceRequirements = mapped
    }

    /**
     * @param values The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
     */
    @JvmName("tyggbpalxhkcslsy")
    public suspend fun resourceRequirements(vararg values: PipeEcsResourceRequirementArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.resourceRequirements = mapped
    }

    internal fun build(): PipeEcsContainerOverrideArgs = PipeEcsContainerOverrideArgs(
        command = command,
        cpu = cpu,
        environment = environment,
        environmentFiles = environmentFiles,
        memory = memory,
        memoryReservation = memoryReservation,
        name = name,
        resourceRequirements = resourceRequirements,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy