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

com.pulumi.gcp.notebooks.kotlin.inputs.RuntimeSoftwareConfigArgs.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.notebooks.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.notebooks.inputs.RuntimeSoftwareConfigArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property customGpuDriverPath Specify a custom Cloud Storage path where the GPU driver is stored.
 * If not specified, we'll automatically choose from official GPU drivers.
 * @property enableHealthMonitoring Verifies core internal services are running. Default: True.
 * @property idleShutdown Runtime will automatically shutdown after idle_shutdown_time.
 * Default: True
 * @property idleShutdownTimeout Time in minutes to wait before shuting down runtime.
 * Default: 180 minutes
 * @property installGpuDriver Install Nvidia Driver automatically.
 * @property kernels Use a list of container images to use as Kernels in the notebook instance.
 * Structure is documented below.
 * @property notebookUpgradeSchedule Cron expression in UTC timezone for schedule instance auto upgrade.
 * Please follow the [cron format](https://en.wikipedia.org/wiki/Cron).
 * @property postStartupScript Path to a Bash script that automatically runs after a notebook instance
 * fully boots up. The path must be a URL or
 * Cloud Storage path (gs://path-to-file/file-name).
 * @property postStartupScriptBehavior Behavior for the post startup script.
 * Possible values are: `POST_STARTUP_SCRIPT_BEHAVIOR_UNSPECIFIED`, `RUN_EVERY_START`, `DOWNLOAD_AND_RUN_EVERY_START`.
 * @property upgradeable (Output)
 * Bool indicating whether an newer image is available in an image family.
 */
public data class RuntimeSoftwareConfigArgs(
    public val customGpuDriverPath: Output? = null,
    public val enableHealthMonitoring: Output? = null,
    public val idleShutdown: Output? = null,
    public val idleShutdownTimeout: Output? = null,
    public val installGpuDriver: Output? = null,
    public val kernels: Output>? = null,
    public val notebookUpgradeSchedule: Output? = null,
    public val postStartupScript: Output? = null,
    public val postStartupScriptBehavior: Output? = null,
    public val upgradeable: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.notebooks.inputs.RuntimeSoftwareConfigArgs =
        com.pulumi.gcp.notebooks.inputs.RuntimeSoftwareConfigArgs.builder()
            .customGpuDriverPath(customGpuDriverPath?.applyValue({ args0 -> args0 }))
            .enableHealthMonitoring(enableHealthMonitoring?.applyValue({ args0 -> args0 }))
            .idleShutdown(idleShutdown?.applyValue({ args0 -> args0 }))
            .idleShutdownTimeout(idleShutdownTimeout?.applyValue({ args0 -> args0 }))
            .installGpuDriver(installGpuDriver?.applyValue({ args0 -> args0 }))
            .kernels(
                kernels?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .notebookUpgradeSchedule(notebookUpgradeSchedule?.applyValue({ args0 -> args0 }))
            .postStartupScript(postStartupScript?.applyValue({ args0 -> args0 }))
            .postStartupScriptBehavior(postStartupScriptBehavior?.applyValue({ args0 -> args0 }))
            .upgradeable(upgradeable?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [RuntimeSoftwareConfigArgs].
 */
@PulumiTagMarker
public class RuntimeSoftwareConfigArgsBuilder internal constructor() {
    private var customGpuDriverPath: Output? = null

    private var enableHealthMonitoring: Output? = null

    private var idleShutdown: Output? = null

    private var idleShutdownTimeout: Output? = null

    private var installGpuDriver: Output? = null

    private var kernels: Output>? = null

    private var notebookUpgradeSchedule: Output? = null

    private var postStartupScript: Output? = null

    private var postStartupScriptBehavior: Output? = null

    private var upgradeable: Output? = null

    /**
     * @param value Specify a custom Cloud Storage path where the GPU driver is stored.
     * If not specified, we'll automatically choose from official GPU drivers.
     */
    @JvmName("ewjujfaqfvmptoef")
    public suspend fun customGpuDriverPath(`value`: Output) {
        this.customGpuDriverPath = value
    }

    /**
     * @param value Verifies core internal services are running. Default: True.
     */
    @JvmName("gwhfmbjbdiwahovr")
    public suspend fun enableHealthMonitoring(`value`: Output) {
        this.enableHealthMonitoring = value
    }

    /**
     * @param value Runtime will automatically shutdown after idle_shutdown_time.
     * Default: True
     */
    @JvmName("tktdutnpgltnkgnn")
    public suspend fun idleShutdown(`value`: Output) {
        this.idleShutdown = value
    }

    /**
     * @param value Time in minutes to wait before shuting down runtime.
     * Default: 180 minutes
     */
    @JvmName("xvcsjpqjyqhosiai")
    public suspend fun idleShutdownTimeout(`value`: Output) {
        this.idleShutdownTimeout = value
    }

    /**
     * @param value Install Nvidia Driver automatically.
     */
    @JvmName("segiculqlalkkcyo")
    public suspend fun installGpuDriver(`value`: Output) {
        this.installGpuDriver = value
    }

    /**
     * @param value Use a list of container images to use as Kernels in the notebook instance.
     * Structure is documented below.
     */
    @JvmName("obdeqilrrmgkhgpd")
    public suspend fun kernels(`value`: Output>) {
        this.kernels = value
    }

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

    /**
     * @param values Use a list of container images to use as Kernels in the notebook instance.
     * Structure is documented below.
     */
    @JvmName("vgeactwcatljtnyb")
    public suspend fun kernels(values: List>) {
        this.kernels = Output.all(values)
    }

    /**
     * @param value Cron expression in UTC timezone for schedule instance auto upgrade.
     * Please follow the [cron format](https://en.wikipedia.org/wiki/Cron).
     */
    @JvmName("bvggsujwbniunlwq")
    public suspend fun notebookUpgradeSchedule(`value`: Output) {
        this.notebookUpgradeSchedule = value
    }

    /**
     * @param value Path to a Bash script that automatically runs after a notebook instance
     * fully boots up. The path must be a URL or
     * Cloud Storage path (gs://path-to-file/file-name).
     */
    @JvmName("cgovoprfvyyxiron")
    public suspend fun postStartupScript(`value`: Output) {
        this.postStartupScript = value
    }

    /**
     * @param value Behavior for the post startup script.
     * Possible values are: `POST_STARTUP_SCRIPT_BEHAVIOR_UNSPECIFIED`, `RUN_EVERY_START`, `DOWNLOAD_AND_RUN_EVERY_START`.
     */
    @JvmName("brukssxtqubpeqjf")
    public suspend fun postStartupScriptBehavior(`value`: Output) {
        this.postStartupScriptBehavior = value
    }

    /**
     * @param value (Output)
     * Bool indicating whether an newer image is available in an image family.
     */
    @JvmName("dxliqppjwvvggmkr")
    public suspend fun upgradeable(`value`: Output) {
        this.upgradeable = value
    }

    /**
     * @param value Specify a custom Cloud Storage path where the GPU driver is stored.
     * If not specified, we'll automatically choose from official GPU drivers.
     */
    @JvmName("pkgnatpoagtdqogc")
    public suspend fun customGpuDriverPath(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.customGpuDriverPath = mapped
    }

    /**
     * @param value Verifies core internal services are running. Default: True.
     */
    @JvmName("mqymqvfbpafmikow")
    public suspend fun enableHealthMonitoring(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.enableHealthMonitoring = mapped
    }

    /**
     * @param value Runtime will automatically shutdown after idle_shutdown_time.
     * Default: True
     */
    @JvmName("ncfgxogpcvadbfct")
    public suspend fun idleShutdown(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.idleShutdown = mapped
    }

    /**
     * @param value Time in minutes to wait before shuting down runtime.
     * Default: 180 minutes
     */
    @JvmName("vqtjiywaymlrmxwp")
    public suspend fun idleShutdownTimeout(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.idleShutdownTimeout = mapped
    }

    /**
     * @param value Install Nvidia Driver automatically.
     */
    @JvmName("nsqsmdqnmrtakhyv")
    public suspend fun installGpuDriver(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.installGpuDriver = mapped
    }

    /**
     * @param value Use a list of container images to use as Kernels in the notebook instance.
     * Structure is documented below.
     */
    @JvmName("yukblkrmsactfohc")
    public suspend fun kernels(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.kernels = mapped
    }

    /**
     * @param argument Use a list of container images to use as Kernels in the notebook instance.
     * Structure is documented below.
     */
    @JvmName("vobeeuhbsjrssqsd")
    public suspend fun kernels(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            RuntimeSoftwareConfigKernelArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.kernels = mapped
    }

    /**
     * @param argument Use a list of container images to use as Kernels in the notebook instance.
     * Structure is documented below.
     */
    @JvmName("qybqbctldanyfppt")
    public suspend fun kernels(vararg argument: suspend RuntimeSoftwareConfigKernelArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            RuntimeSoftwareConfigKernelArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.kernels = mapped
    }

    /**
     * @param argument Use a list of container images to use as Kernels in the notebook instance.
     * Structure is documented below.
     */
    @JvmName("tmtdyckfnmlkwecc")
    public suspend fun kernels(argument: suspend RuntimeSoftwareConfigKernelArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            RuntimeSoftwareConfigKernelArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.kernels = mapped
    }

    /**
     * @param values Use a list of container images to use as Kernels in the notebook instance.
     * Structure is documented below.
     */
    @JvmName("pgdqesexsrqmgwuo")
    public suspend fun kernels(vararg values: RuntimeSoftwareConfigKernelArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.kernels = mapped
    }

    /**
     * @param value Cron expression in UTC timezone for schedule instance auto upgrade.
     * Please follow the [cron format](https://en.wikipedia.org/wiki/Cron).
     */
    @JvmName("svpceqbupmufooxx")
    public suspend fun notebookUpgradeSchedule(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.notebookUpgradeSchedule = mapped
    }

    /**
     * @param value Path to a Bash script that automatically runs after a notebook instance
     * fully boots up. The path must be a URL or
     * Cloud Storage path (gs://path-to-file/file-name).
     */
    @JvmName("ifyxfewroiwpmndg")
    public suspend fun postStartupScript(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.postStartupScript = mapped
    }

    /**
     * @param value Behavior for the post startup script.
     * Possible values are: `POST_STARTUP_SCRIPT_BEHAVIOR_UNSPECIFIED`, `RUN_EVERY_START`, `DOWNLOAD_AND_RUN_EVERY_START`.
     */
    @JvmName("kfdqmdjsbnyhvjau")
    public suspend fun postStartupScriptBehavior(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.postStartupScriptBehavior = mapped
    }

    /**
     * @param value (Output)
     * Bool indicating whether an newer image is available in an image family.
     */
    @JvmName("wilrofruojibnqul")
    public suspend fun upgradeable(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.upgradeable = mapped
    }

    internal fun build(): RuntimeSoftwareConfigArgs = RuntimeSoftwareConfigArgs(
        customGpuDriverPath = customGpuDriverPath,
        enableHealthMonitoring = enableHealthMonitoring,
        idleShutdown = idleShutdown,
        idleShutdownTimeout = idleShutdownTimeout,
        installGpuDriver = installGpuDriver,
        kernels = kernels,
        notebookUpgradeSchedule = notebookUpgradeSchedule,
        postStartupScript = postStartupScript,
        postStartupScriptBehavior = postStartupScriptBehavior,
        upgradeable = upgradeable,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy