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

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

/**
 *
 * @property arguments Specifies a map of arguments to be used when executing this step.
 * @property cacheEnabled Should the image cache be enabled? Defaults to `true`.
 * @property contextAccessToken The token (Git PAT or SAS token of storage account blob) associated with the context for this step.
 * @property contextPath The URL (absolute or relative) of the source context for this step. If the context is an url you can reference a specific branch or folder via `#branch:folder`.
 * @property dockerfilePath The Dockerfile path relative to the source context.
 * @property imageNames Specifies a list of fully qualified image names including the repository and tag.
 * @property pushEnabled Should the image built be pushed to the registry or not? Defaults to `true`.
 * @property secretArguments Specifies a map of *secret* arguments to be used when executing this step.
 * @property target The name of the target build stage for the docker build.
 */
public data class RegistryTaskDockerStepArgs(
    public val arguments: Output>? = null,
    public val cacheEnabled: Output? = null,
    public val contextAccessToken: Output,
    public val contextPath: Output,
    public val dockerfilePath: Output,
    public val imageNames: Output>? = null,
    public val pushEnabled: Output? = null,
    public val secretArguments: Output>? = null,
    public val target: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.containerservice.inputs.RegistryTaskDockerStepArgs =
        com.pulumi.azure.containerservice.inputs.RegistryTaskDockerStepArgs.builder()
            .arguments(
                arguments?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            )
            .cacheEnabled(cacheEnabled?.applyValue({ args0 -> args0 }))
            .contextAccessToken(contextAccessToken.applyValue({ args0 -> args0 }))
            .contextPath(contextPath.applyValue({ args0 -> args0 }))
            .dockerfilePath(dockerfilePath.applyValue({ args0 -> args0 }))
            .imageNames(imageNames?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .pushEnabled(pushEnabled?.applyValue({ args0 -> args0 }))
            .secretArguments(
                secretArguments?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            )
            .target(target?.applyValue({ args0 -> args0 })).build()
}

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

    private var cacheEnabled: Output? = null

    private var contextAccessToken: Output? = null

    private var contextPath: Output? = null

    private var dockerfilePath: Output? = null

    private var imageNames: Output>? = null

    private var pushEnabled: Output? = null

    private var secretArguments: Output>? = null

    private var target: Output? = null

    /**
     * @param value Specifies a map of arguments to be used when executing this step.
     */
    @JvmName("chgaxvfdhkfbpqtg")
    public suspend fun arguments(`value`: Output>) {
        this.arguments = value
    }

    /**
     * @param value Should the image cache be enabled? Defaults to `true`.
     */
    @JvmName("eomyfsdunfurdqkt")
    public suspend fun cacheEnabled(`value`: Output) {
        this.cacheEnabled = value
    }

    /**
     * @param value The token (Git PAT or SAS token of storage account blob) associated with the context for this step.
     */
    @JvmName("duuolkcasdlpfdrn")
    public suspend fun contextAccessToken(`value`: Output) {
        this.contextAccessToken = value
    }

    /**
     * @param value The URL (absolute or relative) of the source context for this step. If the context is an url you can reference a specific branch or folder via `#branch:folder`.
     */
    @JvmName("ufkjlgqtlmjcernm")
    public suspend fun contextPath(`value`: Output) {
        this.contextPath = value
    }

    /**
     * @param value The Dockerfile path relative to the source context.
     */
    @JvmName("fvwfyrxwilcsseoe")
    public suspend fun dockerfilePath(`value`: Output) {
        this.dockerfilePath = value
    }

    /**
     * @param value Specifies a list of fully qualified image names including the repository and tag.
     */
    @JvmName("uwquyudnucofshgt")
    public suspend fun imageNames(`value`: Output>) {
        this.imageNames = value
    }

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

    /**
     * @param values Specifies a list of fully qualified image names including the repository and tag.
     */
    @JvmName("rxpyvujkkjkoovjq")
    public suspend fun imageNames(values: List>) {
        this.imageNames = Output.all(values)
    }

    /**
     * @param value Should the image built be pushed to the registry or not? Defaults to `true`.
     */
    @JvmName("oxkigsvmtoqcrdce")
    public suspend fun pushEnabled(`value`: Output) {
        this.pushEnabled = value
    }

    /**
     * @param value Specifies a map of *secret* arguments to be used when executing this step.
     */
    @JvmName("yombswhfyequfjda")
    public suspend fun secretArguments(`value`: Output>) {
        this.secretArguments = value
    }

    /**
     * @param value The name of the target build stage for the docker build.
     */
    @JvmName("iemttkmxeriuvojl")
    public suspend fun target(`value`: Output) {
        this.target = value
    }

    /**
     * @param value Specifies a map of arguments to be used when executing this step.
     */
    @JvmName("vylpqsasvketifub")
    public suspend fun arguments(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.arguments = mapped
    }

    /**
     * @param values Specifies a map of arguments to be used when executing this step.
     */
    @JvmName("bbtadgfirwhttqif")
    public fun arguments(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.arguments = mapped
    }

    /**
     * @param value Should the image cache be enabled? Defaults to `true`.
     */
    @JvmName("rnkdcxvuwskfmgkk")
    public suspend fun cacheEnabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cacheEnabled = mapped
    }

    /**
     * @param value The token (Git PAT or SAS token of storage account blob) associated with the context for this step.
     */
    @JvmName("amdfxbyqjodpsbhg")
    public suspend fun contextAccessToken(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.contextAccessToken = mapped
    }

    /**
     * @param value The URL (absolute or relative) of the source context for this step. If the context is an url you can reference a specific branch or folder via `#branch:folder`.
     */
    @JvmName("maqdffysodyfjmty")
    public suspend fun contextPath(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.contextPath = mapped
    }

    /**
     * @param value The Dockerfile path relative to the source context.
     */
    @JvmName("qnmaldhfmeculaiy")
    public suspend fun dockerfilePath(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.dockerfilePath = mapped
    }

    /**
     * @param value Specifies a list of fully qualified image names including the repository and tag.
     */
    @JvmName("csklwffndertrvxy")
    public suspend fun imageNames(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.imageNames = mapped
    }

    /**
     * @param values Specifies a list of fully qualified image names including the repository and tag.
     */
    @JvmName("qfcpfnhhkwuhtylj")
    public suspend fun imageNames(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.imageNames = mapped
    }

    /**
     * @param value Should the image built be pushed to the registry or not? Defaults to `true`.
     */
    @JvmName("rqpgaintmcrdiifd")
    public suspend fun pushEnabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.pushEnabled = mapped
    }

    /**
     * @param value Specifies a map of *secret* arguments to be used when executing this step.
     */
    @JvmName("pixdyqbbevesidpp")
    public suspend fun secretArguments(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.secretArguments = mapped
    }

    /**
     * @param values Specifies a map of *secret* arguments to be used when executing this step.
     */
    @JvmName("ataotovdkcivclwf")
    public fun secretArguments(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.secretArguments = mapped
    }

    /**
     * @param value The name of the target build stage for the docker build.
     */
    @JvmName("nffubqdlpywvqkvg")
    public suspend fun target(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.target = mapped
    }

    internal fun build(): RegistryTaskDockerStepArgs = RegistryTaskDockerStepArgs(
        arguments = arguments,
        cacheEnabled = cacheEnabled,
        contextAccessToken = contextAccessToken ?: throw PulumiNullFieldException("contextAccessToken"),
        contextPath = contextPath ?: throw PulumiNullFieldException("contextPath"),
        dockerfilePath = dockerfilePath ?: throw PulumiNullFieldException("dockerfilePath"),
        imageNames = imageNames,
        pushEnabled = pushEnabled,
        secretArguments = secretArguments,
        target = target,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy