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

com.pulumi.gcp.cloudrun.kotlin.inputs.ServiceTemplateSpecVolumeCsiArgs.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: 8.12.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.cloudrun.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.cloudrun.inputs.ServiceTemplateSpecVolumeCsiArgs.builder
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.Map
import kotlin.jvm.JvmName

/**
 *
 * @property driver Unique name representing the type of file system to be created. Cloud Run supports the following values:
 * * gcsfuse.run.googleapis.com: Mount a Google Cloud Storage bucket using GCSFuse. This driver requires the
 * run.googleapis.com/execution-environment annotation to be set to "gen2" and
 * run.googleapis.com/launch-stage set to "BETA" or "ALPHA".
 * @property readOnly If true, all mounts created from this volume will be read-only.
 * @property volumeAttributes Driver-specific attributes. The following options are supported for available drivers:
 * * gcsfuse.run.googleapis.com
 * * bucketName: The name of the Cloud Storage Bucket that backs this volume. The Cloud Run Service identity must have access to this bucket.
 * - - -
 */
public data class ServiceTemplateSpecVolumeCsiArgs(
    public val driver: Output,
    public val readOnly: Output? = null,
    public val volumeAttributes: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.cloudrun.inputs.ServiceTemplateSpecVolumeCsiArgs =
        com.pulumi.gcp.cloudrun.inputs.ServiceTemplateSpecVolumeCsiArgs.builder()
            .driver(driver.applyValue({ args0 -> args0 }))
            .readOnly(readOnly?.applyValue({ args0 -> args0 }))
            .volumeAttributes(
                volumeAttributes?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            ).build()
}

/**
 * Builder for [ServiceTemplateSpecVolumeCsiArgs].
 */
@PulumiTagMarker
public class ServiceTemplateSpecVolumeCsiArgsBuilder internal constructor() {
    private var driver: Output? = null

    private var readOnly: Output? = null

    private var volumeAttributes: Output>? = null

    /**
     * @param value Unique name representing the type of file system to be created. Cloud Run supports the following values:
     * * gcsfuse.run.googleapis.com: Mount a Google Cloud Storage bucket using GCSFuse. This driver requires the
     * run.googleapis.com/execution-environment annotation to be set to "gen2" and
     * run.googleapis.com/launch-stage set to "BETA" or "ALPHA".
     */
    @JvmName("sqkdasvfhduoygkb")
    public suspend fun driver(`value`: Output) {
        this.driver = value
    }

    /**
     * @param value If true, all mounts created from this volume will be read-only.
     */
    @JvmName("pyrxiynysghounvm")
    public suspend fun readOnly(`value`: Output) {
        this.readOnly = value
    }

    /**
     * @param value Driver-specific attributes. The following options are supported for available drivers:
     * * gcsfuse.run.googleapis.com
     * * bucketName: The name of the Cloud Storage Bucket that backs this volume. The Cloud Run Service identity must have access to this bucket.
     * - - -
     */
    @JvmName("qlvnpftgiepdsuwl")
    public suspend fun volumeAttributes(`value`: Output>) {
        this.volumeAttributes = value
    }

    /**
     * @param value Unique name representing the type of file system to be created. Cloud Run supports the following values:
     * * gcsfuse.run.googleapis.com: Mount a Google Cloud Storage bucket using GCSFuse. This driver requires the
     * run.googleapis.com/execution-environment annotation to be set to "gen2" and
     * run.googleapis.com/launch-stage set to "BETA" or "ALPHA".
     */
    @JvmName("qcvsvhhskgtopjaf")
    public suspend fun driver(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.driver = mapped
    }

    /**
     * @param value If true, all mounts created from this volume will be read-only.
     */
    @JvmName("gjppevxgfinbtsdf")
    public suspend fun readOnly(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.readOnly = mapped
    }

    /**
     * @param value Driver-specific attributes. The following options are supported for available drivers:
     * * gcsfuse.run.googleapis.com
     * * bucketName: The name of the Cloud Storage Bucket that backs this volume. The Cloud Run Service identity must have access to this bucket.
     * - - -
     */
    @JvmName("exgsbklplabhrdqe")
    public suspend fun volumeAttributes(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.volumeAttributes = mapped
    }

    /**
     * @param values Driver-specific attributes. The following options are supported for available drivers:
     * * gcsfuse.run.googleapis.com
     * * bucketName: The name of the Cloud Storage Bucket that backs this volume. The Cloud Run Service identity must have access to this bucket.
     * - - -
     */
    @JvmName("nmtcorujqpwjebwb")
    public fun volumeAttributes(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.volumeAttributes = mapped
    }

    internal fun build(): ServiceTemplateSpecVolumeCsiArgs = ServiceTemplateSpecVolumeCsiArgs(
        driver = driver ?: throw PulumiNullFieldException("driver"),
        readOnly = readOnly,
        volumeAttributes = volumeAttributes,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy