Skip to content
v2.277.0

InstanceBlockDeviceMappingProperty Struct ​

Defines block device mappings for the instance used to configure your image.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_imagebuilder as imagebuilder } from 'aws-cdk-lib';
const instanceBlockDeviceMappingProperty: imagebuilder.CfnImageRecipe.InstanceBlockDeviceMappingProperty = {
  deviceName: 'deviceName',
  ebs: {
    deleteOnTermination: false,
    encrypted: false,
    iops: 123,
    kmsKeyId: 'kmsKeyId',
    snapshotId: 'snapshotId',
    throughput: 123,
    volumeSize: 123,
    volumeType: 'volumeType',
  },
  noDevice: 'noDevice',
  virtualName: 'virtualName',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_imagebuilder as imagebuilder

instance_block_device_mapping_property = imagebuilder.CfnImageRecipe.InstanceBlockDeviceMappingProperty(
    device_name="deviceName",
    ebs=imagebuilder.CfnImageRecipe.EbsInstanceBlockDeviceSpecificationProperty(
        delete_on_termination=False,
        encrypted=False,
        iops=123,
        kms_key_id="kmsKeyId",
        snapshot_id="snapshotId",
        throughput=123,
        volume_size=123,
        volume_type="volumeType"
    ),
    no_device="noDevice",
    virtual_name="virtualName"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.imagebuilder.*;

InstanceBlockDeviceMappingProperty instanceBlockDeviceMappingProperty = InstanceBlockDeviceMappingProperty.builder()
        .deviceName("deviceName")
        .ebs(EbsInstanceBlockDeviceSpecificationProperty.builder()
                .deleteOnTermination(false)
                .encrypted(false)
                .iops(123)
                .kmsKeyId("kmsKeyId")
                .snapshotId("snapshotId")
                .throughput(123)
                .volumeSize(123)
                .volumeType("volumeType")
                .build())
        .noDevice("noDevice")
        .virtualName("virtualName")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.ImageBuilder;

var instanceBlockDeviceMappingProperty = new InstanceBlockDeviceMappingProperty {
    DeviceName = "deviceName",
    Ebs = new EbsInstanceBlockDeviceSpecificationProperty {
        DeleteOnTermination = false,
        Encrypted = false,
        Iops = 123,
        KmsKeyId = "kmsKeyId",
        SnapshotId = "snapshotId",
        Throughput = 123,
        VolumeSize = 123,
        VolumeType = "volumeType"
    },
    NoDevice = "noDevice",
    VirtualName = "virtualName"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

instanceBlockDeviceMappingProperty := &InstanceBlockDeviceMappingProperty{
	DeviceName: jsii.String("deviceName"),
	Ebs: &EbsInstanceBlockDeviceSpecificationProperty{
		DeleteOnTermination: jsii.Boolean(false),
		Encrypted: jsii.Boolean(false),
		Iops: jsii.Number(123),
		KmsKeyId: jsii.String("kmsKeyId"),
		SnapshotId: jsii.String("snapshotId"),
		Throughput: jsii.Number(123),
		VolumeSize: jsii.Number(123),
		VolumeType: jsii.String("volumeType"),
	},
	NoDevice: jsii.String("noDevice"),
	VirtualName: jsii.String("virtualName"),
}

Properties ​

deviceNameoptionalstringdevice_nameoptionalstrdeviceNameoptionalStringDeviceNameoptionalstringDeviceNameoptional*string#
The device to which these mappings apply.
Use to manage Amazon EBS-specific configuration for this mapping.
noDeviceoptionalstringno_deviceoptionalstrnoDeviceoptionalStringNoDeviceoptionalstringNoDeviceoptional*string#
Enter an empty string to remove a mapping from the parent image.

The following is an example of an empty string value in the NoDevice field.

NoDevice:""

virtualNameoptionalstringvirtual_nameoptionalstrvirtualNameoptionalStringVirtualNameoptionalstringVirtualNameoptional*string#
Manages the instance ephemeral devices.