com.pulumi.gcp.container.kotlin.inputs.NodePoolNodeConfigGuestAcceleratorArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-gcp-kotlin Show documentation
Show all versions of pulumi-gcp-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.gcp.container.kotlin.inputs
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.container.inputs.NodePoolNodeConfigGuestAcceleratorArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName
/**
*
* @property count The number of the accelerator cards exposed to an instance.
* @property gpuDriverInstallationConfig Configuration for auto installation of GPU driver.
* @property gpuPartitionSize Size of partitions to create on the GPU. Valid values are described in the NVIDIA mig user guide (https://docs.nvidia.com/datacenter/tesla/mig-user-guide/#partitioning)
* @property gpuSharingConfig Configuration for GPU sharing.
* @property type The accelerator type resource name.
*/
public data class NodePoolNodeConfigGuestAcceleratorArgs(
public val count: Output,
public val gpuDriverInstallationConfig: Output? = null,
public val gpuPartitionSize: Output? = null,
public val gpuSharingConfig: Output? =
null,
public val type: Output,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.gcp.container.inputs.NodePoolNodeConfigGuestAcceleratorArgs =
com.pulumi.gcp.container.inputs.NodePoolNodeConfigGuestAcceleratorArgs.builder()
.count(count.applyValue({ args0 -> args0 }))
.gpuDriverInstallationConfig(
gpuDriverInstallationConfig?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.gpuPartitionSize(gpuPartitionSize?.applyValue({ args0 -> args0 }))
.gpuSharingConfig(gpuSharingConfig?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.type(type.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [NodePoolNodeConfigGuestAcceleratorArgs].
*/
@PulumiTagMarker
public class NodePoolNodeConfigGuestAcceleratorArgsBuilder internal constructor() {
private var count: Output? = null
private var gpuDriverInstallationConfig:
Output? = null
private var gpuPartitionSize: Output? = null
private var gpuSharingConfig: Output? =
null
private var type: Output? = null
/**
* @param value The number of the accelerator cards exposed to an instance.
*/
@JvmName("glentiuelrfbklvx")
public suspend fun count(`value`: Output) {
this.count = value
}
/**
* @param value Configuration for auto installation of GPU driver.
*/
@JvmName("cmagrfwqbemwmpwx")
public suspend fun gpuDriverInstallationConfig(`value`: Output) {
this.gpuDriverInstallationConfig = value
}
/**
* @param value Size of partitions to create on the GPU. Valid values are described in the NVIDIA mig user guide (https://docs.nvidia.com/datacenter/tesla/mig-user-guide/#partitioning)
*/
@JvmName("bxklftsnpbmoshpt")
public suspend fun gpuPartitionSize(`value`: Output) {
this.gpuPartitionSize = value
}
/**
* @param value Configuration for GPU sharing.
*/
@JvmName("apbspbjxslweobqq")
public suspend fun gpuSharingConfig(`value`: Output) {
this.gpuSharingConfig = value
}
/**
* @param value The accelerator type resource name.
*/
@JvmName("uqapihpfrottmiwb")
public suspend fun type(`value`: Output) {
this.type = value
}
/**
* @param value The number of the accelerator cards exposed to an instance.
*/
@JvmName("fcjxcxaxkmcdxohf")
public suspend fun count(`value`: Int) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.count = mapped
}
/**
* @param value Configuration for auto installation of GPU driver.
*/
@JvmName("itcphmoyejbiguts")
public suspend fun gpuDriverInstallationConfig(`value`: NodePoolNodeConfigGuestAcceleratorGpuDriverInstallationConfigArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.gpuDriverInstallationConfig = mapped
}
/**
* @param argument Configuration for auto installation of GPU driver.
*/
@JvmName("blpndodurhxbehfq")
public suspend fun gpuDriverInstallationConfig(argument: suspend NodePoolNodeConfigGuestAcceleratorGpuDriverInstallationConfigArgsBuilder.() -> Unit) {
val toBeMapped =
NodePoolNodeConfigGuestAcceleratorGpuDriverInstallationConfigArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.gpuDriverInstallationConfig = mapped
}
/**
* @param value Size of partitions to create on the GPU. Valid values are described in the NVIDIA mig user guide (https://docs.nvidia.com/datacenter/tesla/mig-user-guide/#partitioning)
*/
@JvmName("oykjdrtqshnkinqc")
public suspend fun gpuPartitionSize(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.gpuPartitionSize = mapped
}
/**
* @param value Configuration for GPU sharing.
*/
@JvmName("efahdutmycjeydqg")
public suspend fun gpuSharingConfig(`value`: NodePoolNodeConfigGuestAcceleratorGpuSharingConfigArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.gpuSharingConfig = mapped
}
/**
* @param argument Configuration for GPU sharing.
*/
@JvmName("vdcfsfjffsjvldng")
public suspend fun gpuSharingConfig(argument: suspend NodePoolNodeConfigGuestAcceleratorGpuSharingConfigArgsBuilder.() -> Unit) {
val toBeMapped = NodePoolNodeConfigGuestAcceleratorGpuSharingConfigArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.gpuSharingConfig = mapped
}
/**
* @param value The accelerator type resource name.
*/
@JvmName("ntacqevslxdpxhju")
public suspend fun type(`value`: String) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.type = mapped
}
internal fun build(): NodePoolNodeConfigGuestAcceleratorArgs =
NodePoolNodeConfigGuestAcceleratorArgs(
count = count ?: throw PulumiNullFieldException("count"),
gpuDriverInstallationConfig = gpuDriverInstallationConfig,
gpuPartitionSize = gpuPartitionSize,
gpuSharingConfig = gpuSharingConfig,
type = type ?: throw PulumiNullFieldException("type"),
)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy