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

com.pulumi.azure.containerservice.kotlin.inputs.GroupInitContainerArgs.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.21.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azure.containerservice.kotlin.inputs

import com.pulumi.azure.containerservice.inputs.GroupInitContainerArgs.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.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 *
 * @property commands A list of commands which should be run on the container. Changing this forces a new resource to be created.
 * @property environmentVariables A list of environment variables to be set on the container. Specified as a map of name/value pairs. Changing this forces a new resource to be created.
 * @property image The container image name. Changing this forces a new resource to be created.
 * @property name Specifies the name of the Container. Changing this forces a new resource to be created.
 * @property secureEnvironmentVariables A list of sensitive environment variables to be set on the container. Specified as a map of name/value pairs. Changing this forces a new resource to be created.
 * @property securities The definition of the security context for this container as documented in the `security` block below. Changing this forces a new resource to be created.
 * @property volumes The definition of a volume mount for this container as documented in the `volume` block below. Changing this forces a new resource to be created.
 */
public data class GroupInitContainerArgs(
    public val commands: Output>? = null,
    public val environmentVariables: Output>? = null,
    public val image: Output,
    public val name: Output,
    public val secureEnvironmentVariables: Output>? = null,
    public val securities: Output>? = null,
    public val volumes: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.containerservice.inputs.GroupInitContainerArgs =
        com.pulumi.azure.containerservice.inputs.GroupInitContainerArgs.builder()
            .commands(commands?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .environmentVariables(
                environmentVariables?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            )
            .image(image.applyValue({ args0 -> args0 }))
            .name(name.applyValue({ args0 -> args0 }))
            .secureEnvironmentVariables(
                secureEnvironmentVariables?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            )
            .securities(
                securities?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .volumes(
                volumes?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

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

    private var environmentVariables: Output>? = null

    private var image: Output? = null

    private var name: Output? = null

    private var secureEnvironmentVariables: Output>? = null

    private var securities: Output>? = null

    private var volumes: Output>? = null

    /**
     * @param value A list of commands which should be run on the container. Changing this forces a new resource to be created.
     */
    @JvmName("fjlgafdsrhwavpki")
    public suspend fun commands(`value`: Output>) {
        this.commands = value
    }

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

    /**
     * @param values A list of commands which should be run on the container. Changing this forces a new resource to be created.
     */
    @JvmName("apxuxrvvucuovoyr")
    public suspend fun commands(values: List>) {
        this.commands = Output.all(values)
    }

    /**
     * @param value A list of environment variables to be set on the container. Specified as a map of name/value pairs. Changing this forces a new resource to be created.
     */
    @JvmName("obauxkqislmpewcl")
    public suspend fun environmentVariables(`value`: Output>) {
        this.environmentVariables = value
    }

    /**
     * @param value The container image name. Changing this forces a new resource to be created.
     */
    @JvmName("fgcwxwkmeoklcrxg")
    public suspend fun image(`value`: Output) {
        this.image = value
    }

    /**
     * @param value Specifies the name of the Container. Changing this forces a new resource to be created.
     */
    @JvmName("cbhcmujqlaxwcjkt")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value A list of sensitive environment variables to be set on the container. Specified as a map of name/value pairs. Changing this forces a new resource to be created.
     */
    @JvmName("xegdsmgscvppeqtv")
    public suspend fun secureEnvironmentVariables(`value`: Output>) {
        this.secureEnvironmentVariables = value
    }

    /**
     * @param value The definition of the security context for this container as documented in the `security` block below. Changing this forces a new resource to be created.
     */
    @JvmName("uhqhcfjlimxaysuw")
    public suspend fun securities(`value`: Output>) {
        this.securities = value
    }

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

    /**
     * @param values The definition of the security context for this container as documented in the `security` block below. Changing this forces a new resource to be created.
     */
    @JvmName("buoqmltofykkvxib")
    public suspend fun securities(values: List>) {
        this.securities = Output.all(values)
    }

    /**
     * @param value The definition of a volume mount for this container as documented in the `volume` block below. Changing this forces a new resource to be created.
     */
    @JvmName("birdkyxxwppiyngr")
    public suspend fun volumes(`value`: Output>) {
        this.volumes = value
    }

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

    /**
     * @param values The definition of a volume mount for this container as documented in the `volume` block below. Changing this forces a new resource to be created.
     */
    @JvmName("trcwjkolxpuawnar")
    public suspend fun volumes(values: List>) {
        this.volumes = Output.all(values)
    }

    /**
     * @param value A list of commands which should be run on the container. Changing this forces a new resource to be created.
     */
    @JvmName("ptnljcdexmkkcpfa")
    public suspend fun commands(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.commands = mapped
    }

    /**
     * @param values A list of commands which should be run on the container. Changing this forces a new resource to be created.
     */
    @JvmName("xvngrvdygyxbmaya")
    public suspend fun commands(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.commands = mapped
    }

    /**
     * @param value A list of environment variables to be set on the container. Specified as a map of name/value pairs. Changing this forces a new resource to be created.
     */
    @JvmName("ydptrpomvetbjoqf")
    public suspend fun environmentVariables(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.environmentVariables = mapped
    }

    /**
     * @param values A list of environment variables to be set on the container. Specified as a map of name/value pairs. Changing this forces a new resource to be created.
     */
    @JvmName("rlkxisumjdqjyfxn")
    public fun environmentVariables(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.environmentVariables = mapped
    }

    /**
     * @param value The container image name. Changing this forces a new resource to be created.
     */
    @JvmName("pttsfyituouxmugr")
    public suspend fun image(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.image = mapped
    }

    /**
     * @param value Specifies the name of the Container. Changing this forces a new resource to be created.
     */
    @JvmName("isnhaihhdjwbhaxn")
    public suspend fun name(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value A list of sensitive environment variables to be set on the container. Specified as a map of name/value pairs. Changing this forces a new resource to be created.
     */
    @JvmName("ibiudduwyehpfimk")
    public suspend fun secureEnvironmentVariables(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.secureEnvironmentVariables = mapped
    }

    /**
     * @param values A list of sensitive environment variables to be set on the container. Specified as a map of name/value pairs. Changing this forces a new resource to be created.
     */
    @JvmName("fhssrlgdcjnqrinw")
    public fun secureEnvironmentVariables(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.secureEnvironmentVariables = mapped
    }

    /**
     * @param value The definition of the security context for this container as documented in the `security` block below. Changing this forces a new resource to be created.
     */
    @JvmName("grvamvqknvclbprl")
    public suspend fun securities(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.securities = mapped
    }

    /**
     * @param argument The definition of the security context for this container as documented in the `security` block below. Changing this forces a new resource to be created.
     */
    @JvmName("goqrsxhgikpunmsh")
    public suspend
    fun securities(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            GroupInitContainerSecurityArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.securities = mapped
    }

    /**
     * @param argument The definition of the security context for this container as documented in the `security` block below. Changing this forces a new resource to be created.
     */
    @JvmName("kfhkhobnayvtuqkh")
    public suspend fun securities(
        vararg
        argument: suspend GroupInitContainerSecurityArgsBuilder.() -> Unit,
    ) {
        val toBeMapped = argument.toList().map {
            GroupInitContainerSecurityArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.securities = mapped
    }

    /**
     * @param argument The definition of the security context for this container as documented in the `security` block below. Changing this forces a new resource to be created.
     */
    @JvmName("jkijoodogbumcmrc")
    public suspend
    fun securities(argument: suspend GroupInitContainerSecurityArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            GroupInitContainerSecurityArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.securities = mapped
    }

    /**
     * @param values The definition of the security context for this container as documented in the `security` block below. Changing this forces a new resource to be created.
     */
    @JvmName("tvdwkhvocduqsahp")
    public suspend fun securities(vararg values: GroupInitContainerSecurityArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.securities = mapped
    }

    /**
     * @param value The definition of a volume mount for this container as documented in the `volume` block below. Changing this forces a new resource to be created.
     */
    @JvmName("ietpmmektyajmeri")
    public suspend fun volumes(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.volumes = mapped
    }

    /**
     * @param argument The definition of a volume mount for this container as documented in the `volume` block below. Changing this forces a new resource to be created.
     */
    @JvmName("jvakiblynyhcydhx")
    public suspend
    fun volumes(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            GroupInitContainerVolumeArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.volumes = mapped
    }

    /**
     * @param argument The definition of a volume mount for this container as documented in the `volume` block below. Changing this forces a new resource to be created.
     */
    @JvmName("dhjdiogsjkbmdetr")
    public suspend fun volumes(
        vararg
        argument: suspend GroupInitContainerVolumeArgsBuilder.() -> Unit,
    ) {
        val toBeMapped = argument.toList().map {
            GroupInitContainerVolumeArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.volumes = mapped
    }

    /**
     * @param argument The definition of a volume mount for this container as documented in the `volume` block below. Changing this forces a new resource to be created.
     */
    @JvmName("kcefwpdhfwsmsbyf")
    public suspend fun volumes(argument: suspend GroupInitContainerVolumeArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            GroupInitContainerVolumeArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.volumes = mapped
    }

    /**
     * @param values The definition of a volume mount for this container as documented in the `volume` block below. Changing this forces a new resource to be created.
     */
    @JvmName("phybsgevojcvnbgi")
    public suspend fun volumes(vararg values: GroupInitContainerVolumeArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.volumes = mapped
    }

    internal fun build(): GroupInitContainerArgs = GroupInitContainerArgs(
        commands = commands,
        environmentVariables = environmentVariables,
        image = image ?: throw PulumiNullFieldException("image"),
        name = name ?: throw PulumiNullFieldException("name"),
        secureEnvironmentVariables = secureEnvironmentVariables,
        securities = securities,
        volumes = volumes,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy