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

com.pulumi.azurenative.containerregistry.kotlin.inputs.DockerBuildStepArgs.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: 2.82.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azurenative.containerregistry.kotlin.inputs

import com.pulumi.azurenative.containerregistry.inputs.DockerBuildStepArgs.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.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * The Docker build step.
 * @property arguments The collection of override arguments to be used when executing this build step.
 * @property contextAccessToken The token (git PAT or SAS token of storage account blob) associated with the context for a step.
 * @property contextPath The URL(absolute or relative) of the source context for the task step.
 * @property dockerFilePath The Docker file path relative to the source context.
 * @property imageNames The fully qualified image names including the repository and tag.
 * @property isPushEnabled The value of this property indicates whether the image built should be pushed to the registry or not.
 * @property noCache The value of this property indicates whether the image cache is enabled or not.
 * @property target The name of the target build stage for the docker build.
 * @property type The type of the step.
 * Expected value is 'Docker'.
 */
public data class DockerBuildStepArgs(
    public val arguments: Output>? = null,
    public val contextAccessToken: Output? = null,
    public val contextPath: Output? = null,
    public val dockerFilePath: Output,
    public val imageNames: Output>? = null,
    public val isPushEnabled: Output? = null,
    public val noCache: Output? = null,
    public val target: Output? = null,
    public val type: Output,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.containerregistry.inputs.DockerBuildStepArgs =
        com.pulumi.azurenative.containerregistry.inputs.DockerBuildStepArgs.builder()
            .arguments(
                arguments?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .contextAccessToken(contextAccessToken?.applyValue({ args0 -> args0 }))
            .contextPath(contextPath?.applyValue({ args0 -> args0 }))
            .dockerFilePath(dockerFilePath.applyValue({ args0 -> args0 }))
            .imageNames(imageNames?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .isPushEnabled(isPushEnabled?.applyValue({ args0 -> args0 }))
            .noCache(noCache?.applyValue({ args0 -> args0 }))
            .target(target?.applyValue({ args0 -> args0 }))
            .type(type.applyValue({ args0 -> args0 })).build()
}

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

    private var contextAccessToken: Output? = null

    private var contextPath: Output? = null

    private var dockerFilePath: Output? = null

    private var imageNames: Output>? = null

    private var isPushEnabled: Output? = null

    private var noCache: Output? = null

    private var target: Output? = null

    private var type: Output? = null

    /**
     * @param value The collection of override arguments to be used when executing this build step.
     */
    @JvmName("eatawxarcdwsydch")
    public suspend fun arguments(`value`: Output>) {
        this.arguments = value
    }

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

    /**
     * @param values The collection of override arguments to be used when executing this build step.
     */
    @JvmName("hrvwehdhgfboucig")
    public suspend fun arguments(values: List>) {
        this.arguments = Output.all(values)
    }

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

    /**
     * @param value The URL(absolute or relative) of the source context for the task step.
     */
    @JvmName("xfljvvnpgibtofqe")
    public suspend fun contextPath(`value`: Output) {
        this.contextPath = value
    }

    /**
     * @param value The Docker file path relative to the source context.
     */
    @JvmName("nlobformmwcdhusd")
    public suspend fun dockerFilePath(`value`: Output) {
        this.dockerFilePath = value
    }

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

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

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

    /**
     * @param value The value of this property indicates whether the image built should be pushed to the registry or not.
     */
    @JvmName("cuntoafkeohqwsgj")
    public suspend fun isPushEnabled(`value`: Output) {
        this.isPushEnabled = value
    }

    /**
     * @param value The value of this property indicates whether the image cache is enabled or not.
     */
    @JvmName("ttinksnjdmocsdbm")
    public suspend fun noCache(`value`: Output) {
        this.noCache = value
    }

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

    /**
     * @param value The type of the step.
     * Expected value is 'Docker'.
     */
    @JvmName("bqhfovflcxhdobvp")
    public suspend fun type(`value`: Output) {
        this.type = value
    }

    /**
     * @param value The collection of override arguments to be used when executing this build step.
     */
    @JvmName("yfvhmbefpkjppaqu")
    public suspend fun arguments(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.arguments = mapped
    }

    /**
     * @param argument The collection of override arguments to be used when executing this build step.
     */
    @JvmName("qbqxuaybesdjbnuo")
    public suspend fun arguments(argument: List Unit>) {
        val toBeMapped = argument.toList().map { ArgumentArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.arguments = mapped
    }

    /**
     * @param argument The collection of override arguments to be used when executing this build step.
     */
    @JvmName("ugafwixtoddjlytv")
    public suspend fun arguments(vararg argument: suspend ArgumentArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map { ArgumentArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.arguments = mapped
    }

    /**
     * @param argument The collection of override arguments to be used when executing this build step.
     */
    @JvmName("ouutbphjkxhrftfw")
    public suspend fun arguments(argument: suspend ArgumentArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(ArgumentArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.arguments = mapped
    }

    /**
     * @param values The collection of override arguments to be used when executing this build step.
     */
    @JvmName("voqtpeqaoqebcsfk")
    public suspend fun arguments(vararg values: ArgumentArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.arguments = mapped
    }

    /**
     * @param value The token (git PAT or SAS token of storage account blob) associated with the context for a step.
     */
    @JvmName("xkvnuhvbogeqotjh")
    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 the task step.
     */
    @JvmName("hfwpxcqbpibdjglh")
    public suspend fun contextPath(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.contextPath = mapped
    }

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

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

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

    /**
     * @param value The value of this property indicates whether the image built should be pushed to the registry or not.
     */
    @JvmName("bbompvlfhtmuemit")
    public suspend fun isPushEnabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.isPushEnabled = mapped
    }

    /**
     * @param value The value of this property indicates whether the image cache is enabled or not.
     */
    @JvmName("eulhrffrmojnvcgg")
    public suspend fun noCache(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.noCache = mapped
    }

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

    /**
     * @param value The type of the step.
     * Expected value is 'Docker'.
     */
    @JvmName("ntrmahdgfoainoty")
    public suspend fun type(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.type = mapped
    }

    internal fun build(): DockerBuildStepArgs = DockerBuildStepArgs(
        arguments = arguments,
        contextAccessToken = contextAccessToken,
        contextPath = contextPath,
        dockerFilePath = dockerFilePath ?: throw PulumiNullFieldException("dockerFilePath"),
        imageNames = imageNames,
        isPushEnabled = isPushEnabled,
        noCache = noCache,
        target = target,
        type = type ?: throw PulumiNullFieldException("type"),
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy