Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.awsnative.ec2.kotlin.inputs.LaunchTemplateDataArgs.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.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.ec2.kotlin.inputs
import com.pulumi.awsnative.ec2.inputs.LaunchTemplateDataArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
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 information to include in the launch template.
* You must specify at least one parameter for the launch template data.
* @property blockDeviceMappings The block device mapping.
* @property capacityReservationSpecification The Capacity Reservation targeting option. If you do not specify this parameter, the instance's Capacity Reservation preference defaults to ``open``, which enables it to run in any open Capacity Reservation that has matching attributes (instance type, platform, Availability Zone).
* @property cpuOptions The CPU options for the instance. For more information, see [Optimize CPU options](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) in the *Amazon EC2 User Guide*.
* @property creditSpecification The credit option for CPU usage of the instance. Valid only for T instances.
* @property disableApiStop Indicates whether to enable the instance for stop protection. For more information, see [Enable stop protection for your instance](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-stop-protection.html) in the *Amazon EC2 User Guide*.
* @property disableApiTermination If you set this parameter to ``true``, you can't terminate the instance using the Amazon EC2 console, CLI, or API; otherwise, you can. To change this attribute after launch, use [ModifyInstanceAttribute](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyInstanceAttribute.html). Alternatively, if you set ``InstanceInitiatedShutdownBehavior`` to ``terminate``, you can terminate the instance by running the shutdown command from the instance.
* @property ebsOptimized Indicates whether the instance is optimized for Amazon EBS I/O. This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal Amazon EBS I/O performance. This optimization isn't available with all instance types. Additional usage charges apply when using an EBS-optimized instance.
* @property elasticGpuSpecifications Deprecated.
* Amazon Elastic Graphics reached end of life on January 8, 2024. For workloads that require graphics acceleration, we recommend that you use Amazon EC2 G4ad, G4dn, or G5 instances.
* @property elasticInferenceAccelerators An elastic inference accelerator to associate with the instance. Elastic inference accelerators are a resource you can attach to your Amazon EC2 instances to accelerate your Deep Learning (DL) inference workloads.
* You cannot specify accelerators from different generations in the same request.
* Starting April 15, 2023, AWS will not onboard new customers to Amazon Elastic Inference (EI), and will help current customers migrate their workloads to options that offer better price and performance. After April 15, 2023, new customers will not be able to launch instances with Amazon EI accelerators in Amazon SageMaker, Amazon ECS, or Amazon EC2. However, customers who have used Amazon EI at least once during the past 30-day period are considered current customers and will be able to continue using the service.
* @property enclaveOptions Indicates whether the instance is enabled for AWS Nitro Enclaves. For more information, see [What is Nitro Enclaves?](https://docs.aws.amazon.com/enclaves/latest/user/nitro-enclave.html) in the *Nitro Enclaves User Guide*.
* You can't enable AWS Nitro Enclaves and hibernation on the same instance.
* @property hibernationOptions Indicates whether an instance is enabled for hibernation. This parameter is valid only if the instance meets the [hibernation prerequisites](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/hibernating-prerequisites.html). For more information, see [Hibernate your Amazon EC2 instance](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) in the *Amazon EC2 User Guide*.
* @property iamInstanceProfile The name or Amazon Resource Name (ARN) of an IAM instance profile.
* @property imageId The ID of the AMI. Alternatively, you can specify a Systems Manager parameter, which will resolve to an AMI ID on launch.
* Valid formats:
* + ``ami-17characters00000``
* + ``resolve:ssm:parameter-name``
* + ``resolve:ssm:parameter-name:version-number``
* + ``resolve:ssm:parameter-name:label``
* For more information, see [Use a Systems Manager parameter to find an AMI](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/finding-an-ami.html#using-systems-manager-parameter-to-find-AMI) in the *Amazon Elastic Compute Cloud User Guide*.
* @property instanceInitiatedShutdownBehavior Indicates whether an instance stops or terminates when you initiate shutdown from the instance (using the operating system command for system shutdown).
* Default: ``stop``
* @property instanceMarketOptions The market (purchasing) option for the instances.
* @property instanceRequirements The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance types with these attributes.
* You must specify ``VCpuCount`` and ``MemoryMiB``. All other attributes are optional. Any unspecified optional attribute is set to its default.
* When you specify multiple attributes, you get instance types that satisfy all of the specified attributes. If you specify multiple values for an attribute, you get instance types that satisfy any of the specified values.
* To limit the list of instance types from which Amazon EC2 can identify matching instance types, you can use one of the following parameters, but not both in the same request:
* + ``AllowedInstanceTypes`` - The instance types to include in the list. All other instance types are ignored, even if they match your specified attributes.
* + ``ExcludedInstanceTypes`` - The instance types to exclude from the list, even if they match your specified attributes.
* If you specify ``InstanceRequirements``, you can't specify ``InstanceType``.
* Attribute-based instance type selection is only supported when using Auto Scaling groups, EC2 Fleet, and Spot Fleet to launch instances. If you plan to use the launch template in the [launch instance wizard](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-launch-instance-wizard.html), or with the [RunInstances](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html) API or [AWS::EC2::Instance](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-instance.html) AWS CloudFormation resource, you can't specify ``InstanceRequirements``.
* For more information, see [Attribute-based instance type selection for EC2 Fleet](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-fleet-attribute-based-instance-type-selection.html), [Attribute-based instance type selection for Spot Fleet](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-fleet-attribute-based-instance-type-selection.html), and [Spot placement score](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-placement-score.html) in the *Amazon EC2 User Guide*.
* @property instanceType The instance type. For more information, see [Amazon EC2 instance types](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) in the *Amazon EC2 User Guide*.
* If you specify ``InstanceType``, you can't specify ``InstanceRequirements``.
* @property kernelId The ID of the kernel.
* We recommend that you use PV-GRUB instead of kernels and RAM disks. For more information, see [User Provided Kernels](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) in the *Amazon EC2 User Guide*.
* @property keyName The name of the key pair. You can create a key pair using [CreateKeyPair](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateKeyPair.html) or [ImportKeyPair](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ImportKeyPair.html).
* If you do not specify a key pair, you can't connect to the instance unless you choose an AMI that is configured to allow users another way to log in.
* @property licenseSpecifications The license configurations.
* @property maintenanceOptions The maintenance options of your instance.
* @property metadataOptions The metadata options for the instance. For more information, see [Instance metadata and user data](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-metadata.html) in the *Amazon EC2 User Guide*.
* @property monitoring The monitoring for the instance.
* @property networkInterfaces The network interfaces for the instance.
* @property placement The placement for the instance.
* @property privateDnsNameOptions The hostname type for EC2 instances launched into this subnet and how DNS A and AAAA record queries should be handled. For more information, see [Amazon EC2 instance hostname types](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-naming.html) in the *User Guide*.
* @property ramDiskId The ID of the RAM disk.
* We recommend that you use PV-GRUB instead of kernels and RAM disks. For more information, see [User provided kernels](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) in the *Amazon EC2 User Guide*.
* @property securityGroupIds The IDs of the security groups. You can specify the IDs of existing security groups and references to resources created by the stack template.
* If you specify a network interface, you must specify any security groups as part of the network interface instead.
* @property securityGroups The names of the security groups. For a nondefault VPC, you must use security group IDs instead.
* If you specify a network interface, you must specify any security groups as part of the network interface instead of using this parameter.
* @property tagSpecifications The tags to apply to the resources that are created during instance launch.
* To tag a resource after it has been created, see [CreateTags](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html).
* To tag the launch template itself, use [TagSpecifications](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-launchtemplate.html#cfn-ec2-launchtemplate-tagspecifications).
* @property userData The user data to make available to the instance. You must provide base64-encoded text. User data is limited to 16 KB. For more information, see [Run commands on your Amazon EC2 instance at launch](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) in the *Amazon EC2 User Guide*.
* If you are creating the launch template for use with BATCH, the user data must be provided in the [MIME multi-part archive format](https://docs.aws.amazon.com/https://cloudinit.readthedocs.io/en/latest/topics/format.html#mime-multi-part-archive). For more information, see [Amazon EC2 user data in launch templates](https://docs.aws.amazon.com/batch/latest/userguide/launch-templates.html) in the *User Guide*.
*/
public data class LaunchTemplateDataArgs(
public val blockDeviceMappings: Output>? = null,
public val capacityReservationSpecification: Output? = null,
public val cpuOptions: Output? = null,
public val creditSpecification: Output? = null,
public val disableApiStop: Output? = null,
public val disableApiTermination: Output? = null,
public val ebsOptimized: Output? = null,
public val elasticGpuSpecifications: Output>? =
null,
public val elasticInferenceAccelerators: Output>? = null,
public val enclaveOptions: Output? = null,
public val hibernationOptions: Output? = null,
public val iamInstanceProfile: Output? = null,
public val imageId: Output? = null,
public val instanceInitiatedShutdownBehavior: Output? = null,
public val instanceMarketOptions: Output? = null,
public val instanceRequirements: Output? = null,
public val instanceType: Output? = null,
public val kernelId: Output? = null,
public val keyName: Output? = null,
public val licenseSpecifications: Output>? = null,
public val maintenanceOptions: Output? = null,
public val metadataOptions: Output? = null,
public val monitoring: Output? = null,
public val networkInterfaces: Output>? = null,
public val placement: Output? = null,
public val privateDnsNameOptions: Output? = null,
public val ramDiskId: Output? = null,
public val securityGroupIds: Output>? = null,
public val securityGroups: Output>? = null,
public val tagSpecifications: Output>? = null,
public val userData: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.ec2.inputs.LaunchTemplateDataArgs =
com.pulumi.awsnative.ec2.inputs.LaunchTemplateDataArgs.builder()
.blockDeviceMappings(
blockDeviceMappings?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
)
.capacityReservationSpecification(
capacityReservationSpecification?.applyValue({ args0 ->
args0.let({ args0 -> args0.toJava() })
}),
)
.cpuOptions(cpuOptions?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.creditSpecification(
creditSpecification?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.disableApiStop(disableApiStop?.applyValue({ args0 -> args0 }))
.disableApiTermination(disableApiTermination?.applyValue({ args0 -> args0 }))
.ebsOptimized(ebsOptimized?.applyValue({ args0 -> args0 }))
.elasticGpuSpecifications(
elasticGpuSpecifications?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
)
.elasticInferenceAccelerators(
elasticInferenceAccelerators?.applyValue({ args0 ->
args0.map({ args0 -> args0.let({ args0 -> args0.toJava() }) })
}),
)
.enclaveOptions(enclaveOptions?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.hibernationOptions(
hibernationOptions?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.iamInstanceProfile(
iamInstanceProfile?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.imageId(imageId?.applyValue({ args0 -> args0 }))
.instanceInitiatedShutdownBehavior(
instanceInitiatedShutdownBehavior?.applyValue({ args0 ->
args0
}),
)
.instanceMarketOptions(
instanceMarketOptions?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.instanceRequirements(
instanceRequirements?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.instanceType(instanceType?.applyValue({ args0 -> args0 }))
.kernelId(kernelId?.applyValue({ args0 -> args0 }))
.keyName(keyName?.applyValue({ args0 -> args0 }))
.licenseSpecifications(
licenseSpecifications?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
)
.maintenanceOptions(
maintenanceOptions?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.metadataOptions(metadataOptions?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.monitoring(monitoring?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.networkInterfaces(
networkInterfaces?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
})
}),
)
.placement(placement?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.privateDnsNameOptions(
privateDnsNameOptions?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.ramDiskId(ramDiskId?.applyValue({ args0 -> args0 }))
.securityGroupIds(securityGroupIds?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
.securityGroups(securityGroups?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
.tagSpecifications(
tagSpecifications?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
})
}),
)
.userData(userData?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [LaunchTemplateDataArgs].
*/
@PulumiTagMarker
public class LaunchTemplateDataArgsBuilder internal constructor() {
private var blockDeviceMappings: Output>? = null
private var capacityReservationSpecification:
Output? = null
private var cpuOptions: Output? = null
private var creditSpecification: Output? = null
private var disableApiStop: Output? = null
private var disableApiTermination: Output? = null
private var ebsOptimized: Output? = null
private var elasticGpuSpecifications: Output>? =
null
private var elasticInferenceAccelerators:
Output>? = null
private var enclaveOptions: Output? = null
private var hibernationOptions: Output? = null
private var iamInstanceProfile: Output? = null
private var imageId: Output? = null
private var instanceInitiatedShutdownBehavior: Output? = null
private var instanceMarketOptions: Output? = null
private var instanceRequirements: Output? = null
private var instanceType: Output? = null
private var kernelId: Output? = null
private var keyName: Output? = null
private var licenseSpecifications: Output>? = null
private var maintenanceOptions: Output? = null
private var metadataOptions: Output? = null
private var monitoring: Output? = null
private var networkInterfaces: Output>? = null
private var placement: Output? = null
private var privateDnsNameOptions: Output? = null
private var ramDiskId: Output? = null
private var securityGroupIds: Output>? = null
private var securityGroups: Output>? = null
private var tagSpecifications: Output>? = null
private var userData: Output? = null
/**
* @param value The block device mapping.
*/
@JvmName("evtgddragvywreqi")
public suspend fun blockDeviceMappings(`value`: Output>) {
this.blockDeviceMappings = value
}
@JvmName("iuohovmbkdkwwvyc")
public suspend fun blockDeviceMappings(vararg values: Output) {
this.blockDeviceMappings = Output.all(values.asList())
}
/**
* @param values The block device mapping.
*/
@JvmName("cfobrlhkfhnmikkx")
public suspend fun blockDeviceMappings(values: List>) {
this.blockDeviceMappings = Output.all(values)
}
/**
* @param value The Capacity Reservation targeting option. If you do not specify this parameter, the instance's Capacity Reservation preference defaults to ``open``, which enables it to run in any open Capacity Reservation that has matching attributes (instance type, platform, Availability Zone).
*/
@JvmName("ghmdxnxnkypglryi")
public suspend fun capacityReservationSpecification(`value`: Output) {
this.capacityReservationSpecification = value
}
/**
* @param value The CPU options for the instance. For more information, see [Optimize CPU options](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("emltmkcqnsaybept")
public suspend fun cpuOptions(`value`: Output) {
this.cpuOptions = value
}
/**
* @param value The credit option for CPU usage of the instance. Valid only for T instances.
*/
@JvmName("ualegkkuqobgyjgp")
public suspend fun creditSpecification(`value`: Output) {
this.creditSpecification = value
}
/**
* @param value Indicates whether to enable the instance for stop protection. For more information, see [Enable stop protection for your instance](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-stop-protection.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("gmxvjgwijxnamakr")
public suspend fun disableApiStop(`value`: Output) {
this.disableApiStop = value
}
/**
* @param value If you set this parameter to ``true``, you can't terminate the instance using the Amazon EC2 console, CLI, or API; otherwise, you can. To change this attribute after launch, use [ModifyInstanceAttribute](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyInstanceAttribute.html). Alternatively, if you set ``InstanceInitiatedShutdownBehavior`` to ``terminate``, you can terminate the instance by running the shutdown command from the instance.
*/
@JvmName("tfdhgxbpeufsnccp")
public suspend fun disableApiTermination(`value`: Output) {
this.disableApiTermination = value
}
/**
* @param value Indicates whether the instance is optimized for Amazon EBS I/O. This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal Amazon EBS I/O performance. This optimization isn't available with all instance types. Additional usage charges apply when using an EBS-optimized instance.
*/
@JvmName("ueepfvsrouhwtjgb")
public suspend fun ebsOptimized(`value`: Output) {
this.ebsOptimized = value
}
/**
* @param value Deprecated.
* Amazon Elastic Graphics reached end of life on January 8, 2024. For workloads that require graphics acceleration, we recommend that you use Amazon EC2 G4ad, G4dn, or G5 instances.
*/
@JvmName("rfeqyxwhgqosirno")
public suspend fun elasticGpuSpecifications(`value`: Output>) {
this.elasticGpuSpecifications = value
}
@JvmName("vahoidgmqgdrfrja")
public suspend fun elasticGpuSpecifications(vararg values: Output) {
this.elasticGpuSpecifications = Output.all(values.asList())
}
/**
* @param values Deprecated.
* Amazon Elastic Graphics reached end of life on January 8, 2024. For workloads that require graphics acceleration, we recommend that you use Amazon EC2 G4ad, G4dn, or G5 instances.
*/
@JvmName("evynsdxsdmeghupl")
public suspend fun elasticGpuSpecifications(values: List>) {
this.elasticGpuSpecifications = Output.all(values)
}
/**
* @param value An elastic inference accelerator to associate with the instance. Elastic inference accelerators are a resource you can attach to your Amazon EC2 instances to accelerate your Deep Learning (DL) inference workloads.
* You cannot specify accelerators from different generations in the same request.
* Starting April 15, 2023, AWS will not onboard new customers to Amazon Elastic Inference (EI), and will help current customers migrate their workloads to options that offer better price and performance. After April 15, 2023, new customers will not be able to launch instances with Amazon EI accelerators in Amazon SageMaker, Amazon ECS, or Amazon EC2. However, customers who have used Amazon EI at least once during the past 30-day period are considered current customers and will be able to continue using the service.
*/
@JvmName("pcdyxgqhlkvdhlge")
public suspend fun elasticInferenceAccelerators(`value`: Output>) {
this.elasticInferenceAccelerators = value
}
@JvmName("agphngswgngcqjrl")
public suspend fun elasticInferenceAccelerators(vararg values: Output) {
this.elasticInferenceAccelerators = Output.all(values.asList())
}
/**
* @param values An elastic inference accelerator to associate with the instance. Elastic inference accelerators are a resource you can attach to your Amazon EC2 instances to accelerate your Deep Learning (DL) inference workloads.
* You cannot specify accelerators from different generations in the same request.
* Starting April 15, 2023, AWS will not onboard new customers to Amazon Elastic Inference (EI), and will help current customers migrate their workloads to options that offer better price and performance. After April 15, 2023, new customers will not be able to launch instances with Amazon EI accelerators in Amazon SageMaker, Amazon ECS, or Amazon EC2. However, customers who have used Amazon EI at least once during the past 30-day period are considered current customers and will be able to continue using the service.
*/
@JvmName("hodesepidoirkwoc")
public suspend fun elasticInferenceAccelerators(values: List>) {
this.elasticInferenceAccelerators = Output.all(values)
}
/**
* @param value Indicates whether the instance is enabled for AWS Nitro Enclaves. For more information, see [What is Nitro Enclaves?](https://docs.aws.amazon.com/enclaves/latest/user/nitro-enclave.html) in the *Nitro Enclaves User Guide*.
* You can't enable AWS Nitro Enclaves and hibernation on the same instance.
*/
@JvmName("gcsdxvaqgjcterjj")
public suspend fun enclaveOptions(`value`: Output) {
this.enclaveOptions = value
}
/**
* @param value Indicates whether an instance is enabled for hibernation. This parameter is valid only if the instance meets the [hibernation prerequisites](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/hibernating-prerequisites.html). For more information, see [Hibernate your Amazon EC2 instance](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("mrojridtvlkugqgb")
public suspend fun hibernationOptions(`value`: Output) {
this.hibernationOptions = value
}
/**
* @param value The name or Amazon Resource Name (ARN) of an IAM instance profile.
*/
@JvmName("cciqbvsyshpfaytt")
public suspend fun iamInstanceProfile(`value`: Output) {
this.iamInstanceProfile = value
}
/**
* @param value The ID of the AMI. Alternatively, you can specify a Systems Manager parameter, which will resolve to an AMI ID on launch.
* Valid formats:
* + ``ami-17characters00000``
* + ``resolve:ssm:parameter-name``
* + ``resolve:ssm:parameter-name:version-number``
* + ``resolve:ssm:parameter-name:label``
* For more information, see [Use a Systems Manager parameter to find an AMI](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/finding-an-ami.html#using-systems-manager-parameter-to-find-AMI) in the *Amazon Elastic Compute Cloud User Guide*.
*/
@JvmName("pqfhpfpxfbanihwf")
public suspend fun imageId(`value`: Output) {
this.imageId = value
}
/**
* @param value Indicates whether an instance stops or terminates when you initiate shutdown from the instance (using the operating system command for system shutdown).
* Default: ``stop``
*/
@JvmName("prvjfrdfeewmcduj")
public suspend fun instanceInitiatedShutdownBehavior(`value`: Output) {
this.instanceInitiatedShutdownBehavior = value
}
/**
* @param value The market (purchasing) option for the instances.
*/
@JvmName("qxhpojdoowvyymsj")
public suspend fun instanceMarketOptions(`value`: Output) {
this.instanceMarketOptions = value
}
/**
* @param value The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance types with these attributes.
* You must specify ``VCpuCount`` and ``MemoryMiB``. All other attributes are optional. Any unspecified optional attribute is set to its default.
* When you specify multiple attributes, you get instance types that satisfy all of the specified attributes. If you specify multiple values for an attribute, you get instance types that satisfy any of the specified values.
* To limit the list of instance types from which Amazon EC2 can identify matching instance types, you can use one of the following parameters, but not both in the same request:
* + ``AllowedInstanceTypes`` - The instance types to include in the list. All other instance types are ignored, even if they match your specified attributes.
* + ``ExcludedInstanceTypes`` - The instance types to exclude from the list, even if they match your specified attributes.
* If you specify ``InstanceRequirements``, you can't specify ``InstanceType``.
* Attribute-based instance type selection is only supported when using Auto Scaling groups, EC2 Fleet, and Spot Fleet to launch instances. If you plan to use the launch template in the [launch instance wizard](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-launch-instance-wizard.html), or with the [RunInstances](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html) API or [AWS::EC2::Instance](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-instance.html) AWS CloudFormation resource, you can't specify ``InstanceRequirements``.
* For more information, see [Attribute-based instance type selection for EC2 Fleet](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-fleet-attribute-based-instance-type-selection.html), [Attribute-based instance type selection for Spot Fleet](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-fleet-attribute-based-instance-type-selection.html), and [Spot placement score](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-placement-score.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("qysupkiodwxverst")
public suspend fun instanceRequirements(`value`: Output) {
this.instanceRequirements = value
}
/**
* @param value The instance type. For more information, see [Amazon EC2 instance types](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) in the *Amazon EC2 User Guide*.
* If you specify ``InstanceType``, you can't specify ``InstanceRequirements``.
*/
@JvmName("fymnlyjkdryiqahm")
public suspend fun instanceType(`value`: Output) {
this.instanceType = value
}
/**
* @param value The ID of the kernel.
* We recommend that you use PV-GRUB instead of kernels and RAM disks. For more information, see [User Provided Kernels](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("pdyctqqphdtsfwfs")
public suspend fun kernelId(`value`: Output) {
this.kernelId = value
}
/**
* @param value The name of the key pair. You can create a key pair using [CreateKeyPair](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateKeyPair.html) or [ImportKeyPair](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ImportKeyPair.html).
* If you do not specify a key pair, you can't connect to the instance unless you choose an AMI that is configured to allow users another way to log in.
*/
@JvmName("gqddpmsgkdoxggjt")
public suspend fun keyName(`value`: Output) {
this.keyName = value
}
/**
* @param value The license configurations.
*/
@JvmName("vjbpkhrpvioabuqp")
public suspend fun licenseSpecifications(`value`: Output>) {
this.licenseSpecifications = value
}
@JvmName("vugiktupmhtppohc")
public suspend fun licenseSpecifications(vararg values: Output) {
this.licenseSpecifications = Output.all(values.asList())
}
/**
* @param values The license configurations.
*/
@JvmName("ryrxsfubjkwctwxc")
public suspend fun licenseSpecifications(values: List>) {
this.licenseSpecifications = Output.all(values)
}
/**
* @param value The maintenance options of your instance.
*/
@JvmName("yxulghyvttmhffsa")
public suspend fun maintenanceOptions(`value`: Output) {
this.maintenanceOptions = value
}
/**
* @param value The metadata options for the instance. For more information, see [Instance metadata and user data](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-metadata.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("tgbumplqhxhtfrae")
public suspend fun metadataOptions(`value`: Output) {
this.metadataOptions = value
}
/**
* @param value The monitoring for the instance.
*/
@JvmName("rrosdpxjerjoakho")
public suspend fun monitoring(`value`: Output) {
this.monitoring = value
}
/**
* @param value The network interfaces for the instance.
*/
@JvmName("rfxtwisjwemvccqk")
public suspend fun networkInterfaces(`value`: Output>) {
this.networkInterfaces = value
}
@JvmName("hykhhynuwtmgqvvq")
public suspend fun networkInterfaces(vararg values: Output) {
this.networkInterfaces = Output.all(values.asList())
}
/**
* @param values The network interfaces for the instance.
*/
@JvmName("uqmpjwjjajoyhvuw")
public suspend fun networkInterfaces(values: List>) {
this.networkInterfaces = Output.all(values)
}
/**
* @param value The placement for the instance.
*/
@JvmName("lsutbrmtekokmtdl")
public suspend fun placement(`value`: Output) {
this.placement = value
}
/**
* @param value The hostname type for EC2 instances launched into this subnet and how DNS A and AAAA record queries should be handled. For more information, see [Amazon EC2 instance hostname types](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-naming.html) in the *User Guide*.
*/
@JvmName("ivdjufjddncdodyc")
public suspend fun privateDnsNameOptions(`value`: Output) {
this.privateDnsNameOptions = value
}
/**
* @param value The ID of the RAM disk.
* We recommend that you use PV-GRUB instead of kernels and RAM disks. For more information, see [User provided kernels](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("vmaragjxhljxount")
public suspend fun ramDiskId(`value`: Output) {
this.ramDiskId = value
}
/**
* @param value The IDs of the security groups. You can specify the IDs of existing security groups and references to resources created by the stack template.
* If you specify a network interface, you must specify any security groups as part of the network interface instead.
*/
@JvmName("fmbstjtnrdctxxyv")
public suspend fun securityGroupIds(`value`: Output>) {
this.securityGroupIds = value
}
@JvmName("tbfhjguuoyeeqmlp")
public suspend fun securityGroupIds(vararg values: Output) {
this.securityGroupIds = Output.all(values.asList())
}
/**
* @param values The IDs of the security groups. You can specify the IDs of existing security groups and references to resources created by the stack template.
* If you specify a network interface, you must specify any security groups as part of the network interface instead.
*/
@JvmName("sncturueracyonss")
public suspend fun securityGroupIds(values: List>) {
this.securityGroupIds = Output.all(values)
}
/**
* @param value The names of the security groups. For a nondefault VPC, you must use security group IDs instead.
* If you specify a network interface, you must specify any security groups as part of the network interface instead of using this parameter.
*/
@JvmName("lbuqpwvrvtmrynlm")
public suspend fun securityGroups(`value`: Output>) {
this.securityGroups = value
}
@JvmName("quyyevyqppkmyyjd")
public suspend fun securityGroups(vararg values: Output) {
this.securityGroups = Output.all(values.asList())
}
/**
* @param values The names of the security groups. For a nondefault VPC, you must use security group IDs instead.
* If you specify a network interface, you must specify any security groups as part of the network interface instead of using this parameter.
*/
@JvmName("bnudxtaxbpjeuqix")
public suspend fun securityGroups(values: List>) {
this.securityGroups = Output.all(values)
}
/**
* @param value The tags to apply to the resources that are created during instance launch.
* To tag a resource after it has been created, see [CreateTags](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html).
* To tag the launch template itself, use [TagSpecifications](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-launchtemplate.html#cfn-ec2-launchtemplate-tagspecifications).
*/
@JvmName("uktnxqtbbiekmcan")
public suspend fun tagSpecifications(`value`: Output>) {
this.tagSpecifications = value
}
@JvmName("ylunqgjnlmbkpvxx")
public suspend fun tagSpecifications(vararg values: Output) {
this.tagSpecifications = Output.all(values.asList())
}
/**
* @param values The tags to apply to the resources that are created during instance launch.
* To tag a resource after it has been created, see [CreateTags](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html).
* To tag the launch template itself, use [TagSpecifications](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-launchtemplate.html#cfn-ec2-launchtemplate-tagspecifications).
*/
@JvmName("kobjfjhrossmromo")
public suspend fun tagSpecifications(values: List>) {
this.tagSpecifications = Output.all(values)
}
/**
* @param value The user data to make available to the instance. You must provide base64-encoded text. User data is limited to 16 KB. For more information, see [Run commands on your Amazon EC2 instance at launch](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) in the *Amazon EC2 User Guide*.
* If you are creating the launch template for use with BATCH, the user data must be provided in the [MIME multi-part archive format](https://docs.aws.amazon.com/https://cloudinit.readthedocs.io/en/latest/topics/format.html#mime-multi-part-archive). For more information, see [Amazon EC2 user data in launch templates](https://docs.aws.amazon.com/batch/latest/userguide/launch-templates.html) in the *User Guide*.
*/
@JvmName("mtiigdkhqliwvxgk")
public suspend fun userData(`value`: Output) {
this.userData = value
}
/**
* @param value The block device mapping.
*/
@JvmName("sntlghxbkjmtvlrg")
public suspend fun blockDeviceMappings(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.blockDeviceMappings = mapped
}
/**
* @param argument The block device mapping.
*/
@JvmName("gxiornvvkkjomtwq")
public suspend fun blockDeviceMappings(argument: List Unit>) {
val toBeMapped = argument.toList().map {
LaunchTemplateBlockDeviceMappingArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.blockDeviceMappings = mapped
}
/**
* @param argument The block device mapping.
*/
@JvmName("akhgginqpjubrcxt")
public suspend fun blockDeviceMappings(vararg argument: suspend LaunchTemplateBlockDeviceMappingArgsBuilder.() -> Unit) {
val toBeMapped = argument.toList().map {
LaunchTemplateBlockDeviceMappingArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.blockDeviceMappings = mapped
}
/**
* @param argument The block device mapping.
*/
@JvmName("nrxmmxcktifbhedv")
public suspend fun blockDeviceMappings(argument: suspend LaunchTemplateBlockDeviceMappingArgsBuilder.() -> Unit) {
val toBeMapped = listOf(
LaunchTemplateBlockDeviceMappingArgsBuilder().applySuspend {
argument()
}.build(),
)
val mapped = of(toBeMapped)
this.blockDeviceMappings = mapped
}
/**
* @param values The block device mapping.
*/
@JvmName("pepojbqofldoeqlp")
public suspend fun blockDeviceMappings(vararg values: LaunchTemplateBlockDeviceMappingArgs) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.blockDeviceMappings = mapped
}
/**
* @param value The Capacity Reservation targeting option. If you do not specify this parameter, the instance's Capacity Reservation preference defaults to ``open``, which enables it to run in any open Capacity Reservation that has matching attributes (instance type, platform, Availability Zone).
*/
@JvmName("mdorunjslfukkosg")
public suspend fun capacityReservationSpecification(`value`: LaunchTemplateCapacityReservationSpecificationArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.capacityReservationSpecification = mapped
}
/**
* @param argument The Capacity Reservation targeting option. If you do not specify this parameter, the instance's Capacity Reservation preference defaults to ``open``, which enables it to run in any open Capacity Reservation that has matching attributes (instance type, platform, Availability Zone).
*/
@JvmName("dwpmyckmcprmisdf")
public suspend fun capacityReservationSpecification(argument: suspend LaunchTemplateCapacityReservationSpecificationArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateCapacityReservationSpecificationArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.capacityReservationSpecification = mapped
}
/**
* @param value The CPU options for the instance. For more information, see [Optimize CPU options](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("hfkkhomvkoodqngl")
public suspend fun cpuOptions(`value`: LaunchTemplateCpuOptionsArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.cpuOptions = mapped
}
/**
* @param argument The CPU options for the instance. For more information, see [Optimize CPU options](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("xheeiksnbsrfffru")
public suspend fun cpuOptions(argument: suspend LaunchTemplateCpuOptionsArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateCpuOptionsArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.cpuOptions = mapped
}
/**
* @param value The credit option for CPU usage of the instance. Valid only for T instances.
*/
@JvmName("lnkhlgvhkedahgrg")
public suspend fun creditSpecification(`value`: LaunchTemplateCreditSpecificationArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.creditSpecification = mapped
}
/**
* @param argument The credit option for CPU usage of the instance. Valid only for T instances.
*/
@JvmName("glqnrduwxfokbaec")
public suspend fun creditSpecification(argument: suspend LaunchTemplateCreditSpecificationArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateCreditSpecificationArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.creditSpecification = mapped
}
/**
* @param value Indicates whether to enable the instance for stop protection. For more information, see [Enable stop protection for your instance](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-stop-protection.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("heogoidqiuqwcuef")
public suspend fun disableApiStop(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.disableApiStop = mapped
}
/**
* @param value If you set this parameter to ``true``, you can't terminate the instance using the Amazon EC2 console, CLI, or API; otherwise, you can. To change this attribute after launch, use [ModifyInstanceAttribute](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyInstanceAttribute.html). Alternatively, if you set ``InstanceInitiatedShutdownBehavior`` to ``terminate``, you can terminate the instance by running the shutdown command from the instance.
*/
@JvmName("mlbveaxrmhwythqn")
public suspend fun disableApiTermination(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.disableApiTermination = mapped
}
/**
* @param value Indicates whether the instance is optimized for Amazon EBS I/O. This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal Amazon EBS I/O performance. This optimization isn't available with all instance types. Additional usage charges apply when using an EBS-optimized instance.
*/
@JvmName("iihmgfeckeijacfr")
public suspend fun ebsOptimized(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.ebsOptimized = mapped
}
/**
* @param value Deprecated.
* Amazon Elastic Graphics reached end of life on January 8, 2024. For workloads that require graphics acceleration, we recommend that you use Amazon EC2 G4ad, G4dn, or G5 instances.
*/
@JvmName("pqsgkvhbbyqnrgxo")
public suspend fun elasticGpuSpecifications(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.elasticGpuSpecifications = mapped
}
/**
* @param argument Deprecated.
* Amazon Elastic Graphics reached end of life on January 8, 2024. For workloads that require graphics acceleration, we recommend that you use Amazon EC2 G4ad, G4dn, or G5 instances.
*/
@JvmName("weifmgrqklyxpmvy")
public suspend fun elasticGpuSpecifications(argument: List Unit>) {
val toBeMapped = argument.toList().map {
LaunchTemplateElasticGpuSpecificationArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.elasticGpuSpecifications = mapped
}
/**
* @param argument Deprecated.
* Amazon Elastic Graphics reached end of life on January 8, 2024. For workloads that require graphics acceleration, we recommend that you use Amazon EC2 G4ad, G4dn, or G5 instances.
*/
@JvmName("ddkumbkmvsdhbefv")
public suspend fun elasticGpuSpecifications(vararg argument: suspend LaunchTemplateElasticGpuSpecificationArgsBuilder.() -> Unit) {
val toBeMapped = argument.toList().map {
LaunchTemplateElasticGpuSpecificationArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.elasticGpuSpecifications = mapped
}
/**
* @param argument Deprecated.
* Amazon Elastic Graphics reached end of life on January 8, 2024. For workloads that require graphics acceleration, we recommend that you use Amazon EC2 G4ad, G4dn, or G5 instances.
*/
@JvmName("gbnjbootqgapkugq")
public suspend fun elasticGpuSpecifications(argument: suspend LaunchTemplateElasticGpuSpecificationArgsBuilder.() -> Unit) {
val toBeMapped = listOf(
LaunchTemplateElasticGpuSpecificationArgsBuilder().applySuspend {
argument()
}.build(),
)
val mapped = of(toBeMapped)
this.elasticGpuSpecifications = mapped
}
/**
* @param values Deprecated.
* Amazon Elastic Graphics reached end of life on January 8, 2024. For workloads that require graphics acceleration, we recommend that you use Amazon EC2 G4ad, G4dn, or G5 instances.
*/
@JvmName("jfefnnquipiiiosw")
public suspend fun elasticGpuSpecifications(vararg values: LaunchTemplateElasticGpuSpecificationArgs) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.elasticGpuSpecifications = mapped
}
/**
* @param value An elastic inference accelerator to associate with the instance. Elastic inference accelerators are a resource you can attach to your Amazon EC2 instances to accelerate your Deep Learning (DL) inference workloads.
* You cannot specify accelerators from different generations in the same request.
* Starting April 15, 2023, AWS will not onboard new customers to Amazon Elastic Inference (EI), and will help current customers migrate their workloads to options that offer better price and performance. After April 15, 2023, new customers will not be able to launch instances with Amazon EI accelerators in Amazon SageMaker, Amazon ECS, or Amazon EC2. However, customers who have used Amazon EI at least once during the past 30-day period are considered current customers and will be able to continue using the service.
*/
@JvmName("suwllmakuqoxfpit")
public suspend fun elasticInferenceAccelerators(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.elasticInferenceAccelerators = mapped
}
/**
* @param argument An elastic inference accelerator to associate with the instance. Elastic inference accelerators are a resource you can attach to your Amazon EC2 instances to accelerate your Deep Learning (DL) inference workloads.
* You cannot specify accelerators from different generations in the same request.
* Starting April 15, 2023, AWS will not onboard new customers to Amazon Elastic Inference (EI), and will help current customers migrate their workloads to options that offer better price and performance. After April 15, 2023, new customers will not be able to launch instances with Amazon EI accelerators in Amazon SageMaker, Amazon ECS, or Amazon EC2. However, customers who have used Amazon EI at least once during the past 30-day period are considered current customers and will be able to continue using the service.
*/
@JvmName("tujueomecebrtiva")
public suspend fun elasticInferenceAccelerators(argument: List Unit>) {
val toBeMapped = argument.toList().map {
LaunchTemplateElasticInferenceAcceleratorArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.elasticInferenceAccelerators = mapped
}
/**
* @param argument An elastic inference accelerator to associate with the instance. Elastic inference accelerators are a resource you can attach to your Amazon EC2 instances to accelerate your Deep Learning (DL) inference workloads.
* You cannot specify accelerators from different generations in the same request.
* Starting April 15, 2023, AWS will not onboard new customers to Amazon Elastic Inference (EI), and will help current customers migrate their workloads to options that offer better price and performance. After April 15, 2023, new customers will not be able to launch instances with Amazon EI accelerators in Amazon SageMaker, Amazon ECS, or Amazon EC2. However, customers who have used Amazon EI at least once during the past 30-day period are considered current customers and will be able to continue using the service.
*/
@JvmName("pxmyunrpnbrfdmgf")
public suspend fun elasticInferenceAccelerators(vararg argument: suspend LaunchTemplateElasticInferenceAcceleratorArgsBuilder.() -> Unit) {
val toBeMapped = argument.toList().map {
LaunchTemplateElasticInferenceAcceleratorArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.elasticInferenceAccelerators = mapped
}
/**
* @param argument An elastic inference accelerator to associate with the instance. Elastic inference accelerators are a resource you can attach to your Amazon EC2 instances to accelerate your Deep Learning (DL) inference workloads.
* You cannot specify accelerators from different generations in the same request.
* Starting April 15, 2023, AWS will not onboard new customers to Amazon Elastic Inference (EI), and will help current customers migrate their workloads to options that offer better price and performance. After April 15, 2023, new customers will not be able to launch instances with Amazon EI accelerators in Amazon SageMaker, Amazon ECS, or Amazon EC2. However, customers who have used Amazon EI at least once during the past 30-day period are considered current customers and will be able to continue using the service.
*/
@JvmName("mxunvgmavbutjoco")
public suspend fun elasticInferenceAccelerators(argument: suspend LaunchTemplateElasticInferenceAcceleratorArgsBuilder.() -> Unit) {
val toBeMapped = listOf(
LaunchTemplateElasticInferenceAcceleratorArgsBuilder().applySuspend {
argument()
}.build(),
)
val mapped = of(toBeMapped)
this.elasticInferenceAccelerators = mapped
}
/**
* @param values An elastic inference accelerator to associate with the instance. Elastic inference accelerators are a resource you can attach to your Amazon EC2 instances to accelerate your Deep Learning (DL) inference workloads.
* You cannot specify accelerators from different generations in the same request.
* Starting April 15, 2023, AWS will not onboard new customers to Amazon Elastic Inference (EI), and will help current customers migrate their workloads to options that offer better price and performance. After April 15, 2023, new customers will not be able to launch instances with Amazon EI accelerators in Amazon SageMaker, Amazon ECS, or Amazon EC2. However, customers who have used Amazon EI at least once during the past 30-day period are considered current customers and will be able to continue using the service.
*/
@JvmName("qglpsffdjxhjobrn")
public suspend fun elasticInferenceAccelerators(vararg values: LaunchTemplateElasticInferenceAcceleratorArgs) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.elasticInferenceAccelerators = mapped
}
/**
* @param value Indicates whether the instance is enabled for AWS Nitro Enclaves. For more information, see [What is Nitro Enclaves?](https://docs.aws.amazon.com/enclaves/latest/user/nitro-enclave.html) in the *Nitro Enclaves User Guide*.
* You can't enable AWS Nitro Enclaves and hibernation on the same instance.
*/
@JvmName("ppklxbesdprltlci")
public suspend fun enclaveOptions(`value`: LaunchTemplateEnclaveOptionsArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.enclaveOptions = mapped
}
/**
* @param argument Indicates whether the instance is enabled for AWS Nitro Enclaves. For more information, see [What is Nitro Enclaves?](https://docs.aws.amazon.com/enclaves/latest/user/nitro-enclave.html) in the *Nitro Enclaves User Guide*.
* You can't enable AWS Nitro Enclaves and hibernation on the same instance.
*/
@JvmName("wwifuehcsqudnrup")
public suspend fun enclaveOptions(argument: suspend LaunchTemplateEnclaveOptionsArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateEnclaveOptionsArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.enclaveOptions = mapped
}
/**
* @param value Indicates whether an instance is enabled for hibernation. This parameter is valid only if the instance meets the [hibernation prerequisites](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/hibernating-prerequisites.html). For more information, see [Hibernate your Amazon EC2 instance](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("rdbtinwenttllfjq")
public suspend fun hibernationOptions(`value`: LaunchTemplateHibernationOptionsArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.hibernationOptions = mapped
}
/**
* @param argument Indicates whether an instance is enabled for hibernation. This parameter is valid only if the instance meets the [hibernation prerequisites](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/hibernating-prerequisites.html). For more information, see [Hibernate your Amazon EC2 instance](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("ofrosyqtucnwqxdn")
public suspend fun hibernationOptions(argument: suspend LaunchTemplateHibernationOptionsArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateHibernationOptionsArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.hibernationOptions = mapped
}
/**
* @param value The name or Amazon Resource Name (ARN) of an IAM instance profile.
*/
@JvmName("knijrbyyadombmpf")
public suspend fun iamInstanceProfile(`value`: LaunchTemplateIamInstanceProfileArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.iamInstanceProfile = mapped
}
/**
* @param argument The name or Amazon Resource Name (ARN) of an IAM instance profile.
*/
@JvmName("mloxxchmmunentyp")
public suspend fun iamInstanceProfile(argument: suspend LaunchTemplateIamInstanceProfileArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateIamInstanceProfileArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.iamInstanceProfile = mapped
}
/**
* @param value The ID of the AMI. Alternatively, you can specify a Systems Manager parameter, which will resolve to an AMI ID on launch.
* Valid formats:
* + ``ami-17characters00000``
* + ``resolve:ssm:parameter-name``
* + ``resolve:ssm:parameter-name:version-number``
* + ``resolve:ssm:parameter-name:label``
* For more information, see [Use a Systems Manager parameter to find an AMI](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/finding-an-ami.html#using-systems-manager-parameter-to-find-AMI) in the *Amazon Elastic Compute Cloud User Guide*.
*/
@JvmName("dcssrwekxsxafvtv")
public suspend fun imageId(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.imageId = mapped
}
/**
* @param value Indicates whether an instance stops or terminates when you initiate shutdown from the instance (using the operating system command for system shutdown).
* Default: ``stop``
*/
@JvmName("qhcuqomhwikotdau")
public suspend fun instanceInitiatedShutdownBehavior(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.instanceInitiatedShutdownBehavior = mapped
}
/**
* @param value The market (purchasing) option for the instances.
*/
@JvmName("qhdsptglcogjmoxh")
public suspend fun instanceMarketOptions(`value`: LaunchTemplateInstanceMarketOptionsArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.instanceMarketOptions = mapped
}
/**
* @param argument The market (purchasing) option for the instances.
*/
@JvmName("mwbhdcgfodyaicay")
public suspend fun instanceMarketOptions(argument: suspend LaunchTemplateInstanceMarketOptionsArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateInstanceMarketOptionsArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.instanceMarketOptions = mapped
}
/**
* @param value The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance types with these attributes.
* You must specify ``VCpuCount`` and ``MemoryMiB``. All other attributes are optional. Any unspecified optional attribute is set to its default.
* When you specify multiple attributes, you get instance types that satisfy all of the specified attributes. If you specify multiple values for an attribute, you get instance types that satisfy any of the specified values.
* To limit the list of instance types from which Amazon EC2 can identify matching instance types, you can use one of the following parameters, but not both in the same request:
* + ``AllowedInstanceTypes`` - The instance types to include in the list. All other instance types are ignored, even if they match your specified attributes.
* + ``ExcludedInstanceTypes`` - The instance types to exclude from the list, even if they match your specified attributes.
* If you specify ``InstanceRequirements``, you can't specify ``InstanceType``.
* Attribute-based instance type selection is only supported when using Auto Scaling groups, EC2 Fleet, and Spot Fleet to launch instances. If you plan to use the launch template in the [launch instance wizard](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-launch-instance-wizard.html), or with the [RunInstances](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html) API or [AWS::EC2::Instance](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-instance.html) AWS CloudFormation resource, you can't specify ``InstanceRequirements``.
* For more information, see [Attribute-based instance type selection for EC2 Fleet](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-fleet-attribute-based-instance-type-selection.html), [Attribute-based instance type selection for Spot Fleet](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-fleet-attribute-based-instance-type-selection.html), and [Spot placement score](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-placement-score.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("cfijjuulmwuqvyuh")
public suspend fun instanceRequirements(`value`: LaunchTemplateInstanceRequirementsArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.instanceRequirements = mapped
}
/**
* @param argument The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance types with these attributes.
* You must specify ``VCpuCount`` and ``MemoryMiB``. All other attributes are optional. Any unspecified optional attribute is set to its default.
* When you specify multiple attributes, you get instance types that satisfy all of the specified attributes. If you specify multiple values for an attribute, you get instance types that satisfy any of the specified values.
* To limit the list of instance types from which Amazon EC2 can identify matching instance types, you can use one of the following parameters, but not both in the same request:
* + ``AllowedInstanceTypes`` - The instance types to include in the list. All other instance types are ignored, even if they match your specified attributes.
* + ``ExcludedInstanceTypes`` - The instance types to exclude from the list, even if they match your specified attributes.
* If you specify ``InstanceRequirements``, you can't specify ``InstanceType``.
* Attribute-based instance type selection is only supported when using Auto Scaling groups, EC2 Fleet, and Spot Fleet to launch instances. If you plan to use the launch template in the [launch instance wizard](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-launch-instance-wizard.html), or with the [RunInstances](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html) API or [AWS::EC2::Instance](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-instance.html) AWS CloudFormation resource, you can't specify ``InstanceRequirements``.
* For more information, see [Attribute-based instance type selection for EC2 Fleet](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-fleet-attribute-based-instance-type-selection.html), [Attribute-based instance type selection for Spot Fleet](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-fleet-attribute-based-instance-type-selection.html), and [Spot placement score](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-placement-score.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("vmtyohohqathspyl")
public suspend fun instanceRequirements(argument: suspend LaunchTemplateInstanceRequirementsArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateInstanceRequirementsArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.instanceRequirements = mapped
}
/**
* @param value The instance type. For more information, see [Amazon EC2 instance types](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) in the *Amazon EC2 User Guide*.
* If you specify ``InstanceType``, you can't specify ``InstanceRequirements``.
*/
@JvmName("soefrbkmelvdocsv")
public suspend fun instanceType(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.instanceType = mapped
}
/**
* @param value The ID of the kernel.
* We recommend that you use PV-GRUB instead of kernels and RAM disks. For more information, see [User Provided Kernels](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("rgfglymjlbcwcbqk")
public suspend fun kernelId(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.kernelId = mapped
}
/**
* @param value The name of the key pair. You can create a key pair using [CreateKeyPair](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateKeyPair.html) or [ImportKeyPair](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ImportKeyPair.html).
* If you do not specify a key pair, you can't connect to the instance unless you choose an AMI that is configured to allow users another way to log in.
*/
@JvmName("pxvqqvnduaivkmcv")
public suspend fun keyName(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.keyName = mapped
}
/**
* @param value The license configurations.
*/
@JvmName("wnjfjcywimrbjsef")
public suspend fun licenseSpecifications(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.licenseSpecifications = mapped
}
/**
* @param argument The license configurations.
*/
@JvmName("aybutixggvdlyfwq")
public suspend fun licenseSpecifications(argument: List Unit>) {
val toBeMapped = argument.toList().map {
LaunchTemplateLicenseSpecificationArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.licenseSpecifications = mapped
}
/**
* @param argument The license configurations.
*/
@JvmName("ntmyigieapscrugo")
public suspend fun licenseSpecifications(vararg argument: suspend LaunchTemplateLicenseSpecificationArgsBuilder.() -> Unit) {
val toBeMapped = argument.toList().map {
LaunchTemplateLicenseSpecificationArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.licenseSpecifications = mapped
}
/**
* @param argument The license configurations.
*/
@JvmName("edhxyudjwffcofth")
public suspend fun licenseSpecifications(argument: suspend LaunchTemplateLicenseSpecificationArgsBuilder.() -> Unit) {
val toBeMapped = listOf(
LaunchTemplateLicenseSpecificationArgsBuilder().applySuspend {
argument()
}.build(),
)
val mapped = of(toBeMapped)
this.licenseSpecifications = mapped
}
/**
* @param values The license configurations.
*/
@JvmName("fpxhqsndxennrhkh")
public suspend fun licenseSpecifications(vararg values: LaunchTemplateLicenseSpecificationArgs) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.licenseSpecifications = mapped
}
/**
* @param value The maintenance options of your instance.
*/
@JvmName("wlcaueygivbnjjdi")
public suspend fun maintenanceOptions(`value`: LaunchTemplateMaintenanceOptionsArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.maintenanceOptions = mapped
}
/**
* @param argument The maintenance options of your instance.
*/
@JvmName("nxrgrncdpwxdqqru")
public suspend fun maintenanceOptions(argument: suspend LaunchTemplateMaintenanceOptionsArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateMaintenanceOptionsArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.maintenanceOptions = mapped
}
/**
* @param value The metadata options for the instance. For more information, see [Instance metadata and user data](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-metadata.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("rdpfplusddohensu")
public suspend fun metadataOptions(`value`: LaunchTemplateMetadataOptionsArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.metadataOptions = mapped
}
/**
* @param argument The metadata options for the instance. For more information, see [Instance metadata and user data](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-metadata.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("xknegjxshricxjnr")
public suspend fun metadataOptions(argument: suspend LaunchTemplateMetadataOptionsArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateMetadataOptionsArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.metadataOptions = mapped
}
/**
* @param value The monitoring for the instance.
*/
@JvmName("gtreiisktcqlpiup")
public suspend fun monitoring(`value`: LaunchTemplateMonitoringArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.monitoring = mapped
}
/**
* @param argument The monitoring for the instance.
*/
@JvmName("bvkioiupqfufrxrl")
public suspend fun monitoring(argument: suspend LaunchTemplateMonitoringArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplateMonitoringArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.monitoring = mapped
}
/**
* @param value The network interfaces for the instance.
*/
@JvmName("yptkujdxkwfpcvui")
public suspend fun networkInterfaces(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.networkInterfaces = mapped
}
/**
* @param argument The network interfaces for the instance.
*/
@JvmName("iolnporjjbmonisj")
public suspend fun networkInterfaces(argument: List Unit>) {
val toBeMapped = argument.toList().map {
LaunchTemplateNetworkInterfaceArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.networkInterfaces = mapped
}
/**
* @param argument The network interfaces for the instance.
*/
@JvmName("jsfbipdwyhahxoud")
public suspend fun networkInterfaces(vararg argument: suspend LaunchTemplateNetworkInterfaceArgsBuilder.() -> Unit) {
val toBeMapped = argument.toList().map {
LaunchTemplateNetworkInterfaceArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.networkInterfaces = mapped
}
/**
* @param argument The network interfaces for the instance.
*/
@JvmName("xpexmpiayftkrcxu")
public suspend fun networkInterfaces(argument: suspend LaunchTemplateNetworkInterfaceArgsBuilder.() -> Unit) {
val toBeMapped = listOf(
LaunchTemplateNetworkInterfaceArgsBuilder().applySuspend {
argument()
}.build(),
)
val mapped = of(toBeMapped)
this.networkInterfaces = mapped
}
/**
* @param values The network interfaces for the instance.
*/
@JvmName("aicuxarsvxumaqlt")
public suspend fun networkInterfaces(vararg values: LaunchTemplateNetworkInterfaceArgs) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.networkInterfaces = mapped
}
/**
* @param value The placement for the instance.
*/
@JvmName("ctripphvugtohxej")
public suspend fun placement(`value`: LaunchTemplatePlacementArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.placement = mapped
}
/**
* @param argument The placement for the instance.
*/
@JvmName("hylvpymkgxswmvil")
public suspend fun placement(argument: suspend LaunchTemplatePlacementArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplatePlacementArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.placement = mapped
}
/**
* @param value The hostname type for EC2 instances launched into this subnet and how DNS A and AAAA record queries should be handled. For more information, see [Amazon EC2 instance hostname types](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-naming.html) in the *User Guide*.
*/
@JvmName("jljtvgxutuhjhqhu")
public suspend fun privateDnsNameOptions(`value`: LaunchTemplatePrivateDnsNameOptionsArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.privateDnsNameOptions = mapped
}
/**
* @param argument The hostname type for EC2 instances launched into this subnet and how DNS A and AAAA record queries should be handled. For more information, see [Amazon EC2 instance hostname types](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-naming.html) in the *User Guide*.
*/
@JvmName("trgxhgkupvdrbcrw")
public suspend fun privateDnsNameOptions(argument: suspend LaunchTemplatePrivateDnsNameOptionsArgsBuilder.() -> Unit) {
val toBeMapped = LaunchTemplatePrivateDnsNameOptionsArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.privateDnsNameOptions = mapped
}
/**
* @param value The ID of the RAM disk.
* We recommend that you use PV-GRUB instead of kernels and RAM disks. For more information, see [User provided kernels](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) in the *Amazon EC2 User Guide*.
*/
@JvmName("iijtxpiwsejyjwql")
public suspend fun ramDiskId(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.ramDiskId = mapped
}
/**
* @param value The IDs of the security groups. You can specify the IDs of existing security groups and references to resources created by the stack template.
* If you specify a network interface, you must specify any security groups as part of the network interface instead.
*/
@JvmName("swthqykkpixsynpx")
public suspend fun securityGroupIds(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.securityGroupIds = mapped
}
/**
* @param values The IDs of the security groups. You can specify the IDs of existing security groups and references to resources created by the stack template.
* If you specify a network interface, you must specify any security groups as part of the network interface instead.
*/
@JvmName("ubivfkqlogermqmb")
public suspend fun securityGroupIds(vararg values: String) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.securityGroupIds = mapped
}
/**
* @param value The names of the security groups. For a nondefault VPC, you must use security group IDs instead.
* If you specify a network interface, you must specify any security groups as part of the network interface instead of using this parameter.
*/
@JvmName("kteawkhvoyxqcejd")
public suspend fun securityGroups(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.securityGroups = mapped
}
/**
* @param values The names of the security groups. For a nondefault VPC, you must use security group IDs instead.
* If you specify a network interface, you must specify any security groups as part of the network interface instead of using this parameter.
*/
@JvmName("lhmdlrehsfsaokkx")
public suspend fun securityGroups(vararg values: String) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.securityGroups = mapped
}
/**
* @param value The tags to apply to the resources that are created during instance launch.
* To tag a resource after it has been created, see [CreateTags](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html).
* To tag the launch template itself, use [TagSpecifications](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-launchtemplate.html#cfn-ec2-launchtemplate-tagspecifications).
*/
@JvmName("ddlnfrhkhieiwugo")
public suspend fun tagSpecifications(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.tagSpecifications = mapped
}
/**
* @param argument The tags to apply to the resources that are created during instance launch.
* To tag a resource after it has been created, see [CreateTags](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html).
* To tag the launch template itself, use [TagSpecifications](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-launchtemplate.html#cfn-ec2-launchtemplate-tagspecifications).
*/
@JvmName("yaywifubduhdrklb")
public suspend fun tagSpecifications(argument: List Unit>) {
val toBeMapped = argument.toList().map {
TagSpecificationArgsBuilder().applySuspend {
it()
}.build()
}
val mapped = of(toBeMapped)
this.tagSpecifications = mapped
}
/**
* @param argument The tags to apply to the resources that are created during instance launch.
* To tag a resource after it has been created, see [CreateTags](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html).
* To tag the launch template itself, use [TagSpecifications](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-launchtemplate.html#cfn-ec2-launchtemplate-tagspecifications).
*/
@JvmName("dfyguwlhdkdudryb")
public suspend fun tagSpecifications(vararg argument: suspend TagSpecificationArgsBuilder.() -> Unit) {
val toBeMapped = argument.toList().map {
TagSpecificationArgsBuilder().applySuspend {
it()
}.build()
}
val mapped = of(toBeMapped)
this.tagSpecifications = mapped
}
/**
* @param argument The tags to apply to the resources that are created during instance launch.
* To tag a resource after it has been created, see [CreateTags](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html).
* To tag the launch template itself, use [TagSpecifications](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-launchtemplate.html#cfn-ec2-launchtemplate-tagspecifications).
*/
@JvmName("wppywjspaancdpno")
public suspend fun tagSpecifications(argument: suspend TagSpecificationArgsBuilder.() -> Unit) {
val toBeMapped = listOf(TagSpecificationArgsBuilder().applySuspend { argument() }.build())
val mapped = of(toBeMapped)
this.tagSpecifications = mapped
}
/**
* @param values The tags to apply to the resources that are created during instance launch.
* To tag a resource after it has been created, see [CreateTags](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html).
* To tag the launch template itself, use [TagSpecifications](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-launchtemplate.html#cfn-ec2-launchtemplate-tagspecifications).
*/
@JvmName("cahvkixryghcrsgr")
public suspend fun tagSpecifications(vararg values: TagSpecificationArgs) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.tagSpecifications = mapped
}
/**
* @param value The user data to make available to the instance. You must provide base64-encoded text. User data is limited to 16 KB. For more information, see [Run commands on your Amazon EC2 instance at launch](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) in the *Amazon EC2 User Guide*.
* If you are creating the launch template for use with BATCH, the user data must be provided in the [MIME multi-part archive format](https://docs.aws.amazon.com/https://cloudinit.readthedocs.io/en/latest/topics/format.html#mime-multi-part-archive). For more information, see [Amazon EC2 user data in launch templates](https://docs.aws.amazon.com/batch/latest/userguide/launch-templates.html) in the *User Guide*.
*/
@JvmName("vacabyluntfoppip")
public suspend fun userData(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.userData = mapped
}
internal fun build(): LaunchTemplateDataArgs = LaunchTemplateDataArgs(
blockDeviceMappings = blockDeviceMappings,
capacityReservationSpecification = capacityReservationSpecification,
cpuOptions = cpuOptions,
creditSpecification = creditSpecification,
disableApiStop = disableApiStop,
disableApiTermination = disableApiTermination,
ebsOptimized = ebsOptimized,
elasticGpuSpecifications = elasticGpuSpecifications,
elasticInferenceAccelerators = elasticInferenceAccelerators,
enclaveOptions = enclaveOptions,
hibernationOptions = hibernationOptions,
iamInstanceProfile = iamInstanceProfile,
imageId = imageId,
instanceInitiatedShutdownBehavior = instanceInitiatedShutdownBehavior,
instanceMarketOptions = instanceMarketOptions,
instanceRequirements = instanceRequirements,
instanceType = instanceType,
kernelId = kernelId,
keyName = keyName,
licenseSpecifications = licenseSpecifications,
maintenanceOptions = maintenanceOptions,
metadataOptions = metadataOptions,
monitoring = monitoring,
networkInterfaces = networkInterfaces,
placement = placement,
privateDnsNameOptions = privateDnsNameOptions,
ramDiskId = ramDiskId,
securityGroupIds = securityGroupIds,
securityGroups = securityGroups,
tagSpecifications = tagSpecifications,
userData = userData,
)
}