com.pulumi.awsnative.ec2.kotlin.inputs.SpotFleetBlockDeviceMappingArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-native-kotlin Show documentation
Show all versions of pulumi-aws-native-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.awsnative.ec2.kotlin.inputs
import com.pulumi.awsnative.ec2.inputs.SpotFleetBlockDeviceMappingArgs.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.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName
/**
*
* @property deviceName The device name (for example, `/dev/sdh` or `xvdh` ).
* @property ebs Parameters used to automatically set up EBS volumes when the instance is launched.
* @property noDevice To omit the device from the block device mapping, specify an empty string. When this property is specified, the device is removed from the block device mapping regardless of the assigned value.
* @property virtualName The virtual device name ( `ephemeral` N). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings for `ephemeral0` and `ephemeral1` . The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.
* NVMe instance store volumes are automatically enumerated and assigned a device name. Including them in your block device mapping has no effect.
* Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
*/
public data class SpotFleetBlockDeviceMappingArgs(
public val deviceName: Output,
public val ebs: Output? = null,
public val noDevice: Output? = null,
public val virtualName: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.ec2.inputs.SpotFleetBlockDeviceMappingArgs =
com.pulumi.awsnative.ec2.inputs.SpotFleetBlockDeviceMappingArgs.builder()
.deviceName(deviceName.applyValue({ args0 -> args0 }))
.ebs(ebs?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.noDevice(noDevice?.applyValue({ args0 -> args0 }))
.virtualName(virtualName?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [SpotFleetBlockDeviceMappingArgs].
*/
@PulumiTagMarker
public class SpotFleetBlockDeviceMappingArgsBuilder internal constructor() {
private var deviceName: Output? = null
private var ebs: Output? = null
private var noDevice: Output? = null
private var virtualName: Output? = null
/**
* @param value The device name (for example, `/dev/sdh` or `xvdh` ).
*/
@JvmName("pefguggbssrdipxy")
public suspend fun deviceName(`value`: Output) {
this.deviceName = value
}
/**
* @param value Parameters used to automatically set up EBS volumes when the instance is launched.
*/
@JvmName("uvmwegaygqvbvpeg")
public suspend fun ebs(`value`: Output) {
this.ebs = value
}
/**
* @param value To omit the device from the block device mapping, specify an empty string. When this property is specified, the device is removed from the block device mapping regardless of the assigned value.
*/
@JvmName("ntrkiadmyhjggqpl")
public suspend fun noDevice(`value`: Output) {
this.noDevice = value
}
/**
* @param value The virtual device name ( `ephemeral` N). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings for `ephemeral0` and `ephemeral1` . The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.
* NVMe instance store volumes are automatically enumerated and assigned a device name. Including them in your block device mapping has no effect.
* Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
*/
@JvmName("nvhypwevlmfwydxs")
public suspend fun virtualName(`value`: Output) {
this.virtualName = value
}
/**
* @param value The device name (for example, `/dev/sdh` or `xvdh` ).
*/
@JvmName("wowfcpqqjgyxvgnr")
public suspend fun deviceName(`value`: String) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.deviceName = mapped
}
/**
* @param value Parameters used to automatically set up EBS volumes when the instance is launched.
*/
@JvmName("bhrukdppmmnbyyde")
public suspend fun ebs(`value`: SpotFleetEbsBlockDeviceArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.ebs = mapped
}
/**
* @param argument Parameters used to automatically set up EBS volumes when the instance is launched.
*/
@JvmName("vycwgyifhwdjtuue")
public suspend fun ebs(argument: suspend SpotFleetEbsBlockDeviceArgsBuilder.() -> Unit) {
val toBeMapped = SpotFleetEbsBlockDeviceArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.ebs = mapped
}
/**
* @param value To omit the device from the block device mapping, specify an empty string. When this property is specified, the device is removed from the block device mapping regardless of the assigned value.
*/
@JvmName("yakcxnipclcomoqs")
public suspend fun noDevice(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.noDevice = mapped
}
/**
* @param value The virtual device name ( `ephemeral` N). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings for `ephemeral0` and `ephemeral1` . The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.
* NVMe instance store volumes are automatically enumerated and assigned a device name. Including them in your block device mapping has no effect.
* Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
*/
@JvmName("nqmfnqideahrrvwa")
public suspend fun virtualName(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.virtualName = mapped
}
internal fun build(): SpotFleetBlockDeviceMappingArgs = SpotFleetBlockDeviceMappingArgs(
deviceName = deviceName ?: throw PulumiNullFieldException("deviceName"),
ebs = ebs,
noDevice = noDevice,
virtualName = virtualName,
)
}