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

com.pulumi.awsnative.apprunner.kotlin.inputs.ServiceCodeConfigurationValuesArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.awsnative.apprunner.kotlin.inputs

import com.pulumi.awsnative.apprunner.inputs.ServiceCodeConfigurationValuesArgs.builder
import com.pulumi.awsnative.apprunner.kotlin.enums.ServiceCodeConfigurationValuesRuntime
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.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * Code Configuration Values
 * @property buildCommand Build Command
 * @property port Port
 * @property runtime Runtime
 * @property runtimeEnvironmentSecrets The secrets and parameters that get referenced by your service as environment variables
 * @property runtimeEnvironmentVariables The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.
 * @property startCommand Start Command
 */
public data class ServiceCodeConfigurationValuesArgs(
    public val buildCommand: Output? = null,
    public val port: Output? = null,
    public val runtime: Output,
    public val runtimeEnvironmentSecrets: Output>? = null,
    public val runtimeEnvironmentVariables: Output>? = null,
    public val startCommand: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.apprunner.inputs.ServiceCodeConfigurationValuesArgs =
        com.pulumi.awsnative.apprunner.inputs.ServiceCodeConfigurationValuesArgs.builder()
            .buildCommand(buildCommand?.applyValue({ args0 -> args0 }))
            .port(port?.applyValue({ args0 -> args0 }))
            .runtime(runtime.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .runtimeEnvironmentSecrets(
                runtimeEnvironmentSecrets?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .runtimeEnvironmentVariables(
                runtimeEnvironmentVariables?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .startCommand(startCommand?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [ServiceCodeConfigurationValuesArgs].
 */
@PulumiTagMarker
public class ServiceCodeConfigurationValuesArgsBuilder internal constructor() {
    private var buildCommand: Output? = null

    private var port: Output? = null

    private var runtime: Output? = null

    private var runtimeEnvironmentSecrets: Output>? = null

    private var runtimeEnvironmentVariables: Output>? = null

    private var startCommand: Output? = null

    /**
     * @param value Build Command
     */
    @JvmName("smmbcskujjcpmugl")
    public suspend fun buildCommand(`value`: Output) {
        this.buildCommand = value
    }

    /**
     * @param value Port
     */
    @JvmName("uqqcbnrjdqpfoiye")
    public suspend fun port(`value`: Output) {
        this.port = value
    }

    /**
     * @param value Runtime
     */
    @JvmName("qgthehvmtnnrvwbj")
    public suspend fun runtime(`value`: Output) {
        this.runtime = value
    }

    /**
     * @param value The secrets and parameters that get referenced by your service as environment variables
     */
    @JvmName("gamqkevrfawqtwui")
    public suspend fun runtimeEnvironmentSecrets(`value`: Output>) {
        this.runtimeEnvironmentSecrets = value
    }

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

    /**
     * @param values The secrets and parameters that get referenced by your service as environment variables
     */
    @JvmName("kmohyoxxonjdebqh")
    public suspend fun runtimeEnvironmentSecrets(values: List>) {
        this.runtimeEnvironmentSecrets = Output.all(values)
    }

    /**
     * @param value The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.
     */
    @JvmName("bodcmjgxpavkekwd")
    public suspend fun runtimeEnvironmentVariables(`value`: Output>) {
        this.runtimeEnvironmentVariables = value
    }

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

    /**
     * @param values The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.
     */
    @JvmName("wcftpcxifjpqlegx")
    public suspend fun runtimeEnvironmentVariables(values: List>) {
        this.runtimeEnvironmentVariables = Output.all(values)
    }

    /**
     * @param value Start Command
     */
    @JvmName("utonjyudfictmgbl")
    public suspend fun startCommand(`value`: Output) {
        this.startCommand = value
    }

    /**
     * @param value Build Command
     */
    @JvmName("jfxdspomhdthhtip")
    public suspend fun buildCommand(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.buildCommand = mapped
    }

    /**
     * @param value Port
     */
    @JvmName("xaifwbdmihjyntux")
    public suspend fun port(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.port = mapped
    }

    /**
     * @param value Runtime
     */
    @JvmName("pvwvovvnksftunar")
    public suspend fun runtime(`value`: ServiceCodeConfigurationValuesRuntime) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.runtime = mapped
    }

    /**
     * @param value The secrets and parameters that get referenced by your service as environment variables
     */
    @JvmName("tvikafqilfuaukie")
    public suspend fun runtimeEnvironmentSecrets(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.runtimeEnvironmentSecrets = mapped
    }

    /**
     * @param argument The secrets and parameters that get referenced by your service as environment variables
     */
    @JvmName("djkkgqltfovfibrf")
    public suspend fun runtimeEnvironmentSecrets(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ServiceKeyValuePairArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.runtimeEnvironmentSecrets = mapped
    }

    /**
     * @param argument The secrets and parameters that get referenced by your service as environment variables
     */
    @JvmName("vehffahpfhjaqdey")
    public suspend fun runtimeEnvironmentSecrets(vararg argument: suspend ServiceKeyValuePairArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ServiceKeyValuePairArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.runtimeEnvironmentSecrets = mapped
    }

    /**
     * @param argument The secrets and parameters that get referenced by your service as environment variables
     */
    @JvmName("ryfkubtxsbipopsh")
    public suspend fun runtimeEnvironmentSecrets(argument: suspend ServiceKeyValuePairArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(ServiceKeyValuePairArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.runtimeEnvironmentSecrets = mapped
    }

    /**
     * @param values The secrets and parameters that get referenced by your service as environment variables
     */
    @JvmName("kjprmyfojfhbwshh")
    public suspend fun runtimeEnvironmentSecrets(vararg values: ServiceKeyValuePairArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.runtimeEnvironmentSecrets = mapped
    }

    /**
     * @param value The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.
     */
    @JvmName("lftgphvpsaruxgbk")
    public suspend fun runtimeEnvironmentVariables(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.runtimeEnvironmentVariables = mapped
    }

    /**
     * @param argument The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.
     */
    @JvmName("gpocqjaydjdwcecc")
    public suspend fun runtimeEnvironmentVariables(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ServiceKeyValuePairArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.runtimeEnvironmentVariables = mapped
    }

    /**
     * @param argument The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.
     */
    @JvmName("nnrwtjokeuxfkxfg")
    public suspend fun runtimeEnvironmentVariables(vararg argument: suspend ServiceKeyValuePairArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ServiceKeyValuePairArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.runtimeEnvironmentVariables = mapped
    }

    /**
     * @param argument The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.
     */
    @JvmName("ebrpfwqmlmrvanfd")
    public suspend fun runtimeEnvironmentVariables(argument: suspend ServiceKeyValuePairArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(ServiceKeyValuePairArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.runtimeEnvironmentVariables = mapped
    }

    /**
     * @param values The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.
     */
    @JvmName("xhvhnfjwdtjertcl")
    public suspend fun runtimeEnvironmentVariables(vararg values: ServiceKeyValuePairArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.runtimeEnvironmentVariables = mapped
    }

    /**
     * @param value Start Command
     */
    @JvmName("qtmtrkauhedmsulq")
    public suspend fun startCommand(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.startCommand = mapped
    }

    internal fun build(): ServiceCodeConfigurationValuesArgs = ServiceCodeConfigurationValuesArgs(
        buildCommand = buildCommand,
        port = port,
        runtime = runtime ?: throw PulumiNullFieldException("runtime"),
        runtimeEnvironmentSecrets = runtimeEnvironmentSecrets,
        runtimeEnvironmentVariables = runtimeEnvironmentVariables,
        startCommand = startCommand,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy