AWS SDK for Go (PILOT)
API Reference

PREVIEW DOCUMENTATION - This is a preview of a new format for the AWS SDK for Go API Reference documentation. For the current AWS SDK for Go API Reference, see https://docs.aws.amazon.com/sdk-for-go/api/.

We welcome your feedback on this new version of the documentation. Send your comments to aws-sdkdocs-feedback@amazon.com.

BlockDeviceMapping

import "github.com/aws/aws-sdk-go/service/ec2"

type BlockDeviceMapping struct { DeviceName *string `locationName:"deviceName" type:"string"` Ebs *EbsBlockDevice `locationName:"ebs" type:"structure"` NoDevice *string `locationName:"noDevice" type:"string"` VirtualName *string `locationName:"virtualName" type:"string"` }

Describes a block device mapping.

DeviceName

Type: *string

The device name (for example, /dev/sdh or xvdh).

Ebs

Describes a block device for an EBS volume.

NoDevice

Type: *string

Suppresses the specified device included in the block device mapping of the AMI.

VirtualName

Type: *string

The virtual device name (ephemeralN). 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.

Method

GoString

func (s BlockDeviceMapping) GoString() string

GoString returns the string representation

SetDeviceName

func (s *BlockDeviceMapping) SetDeviceName(v string) *BlockDeviceMapping

SetDeviceName sets the DeviceName field's value.

SetEbs

func (s *BlockDeviceMapping) SetEbs(v *EbsBlockDevice) *BlockDeviceMapping

SetEbs sets the Ebs field's value.

SetNoDevice

func (s *BlockDeviceMapping) SetNoDevice(v string) *BlockDeviceMapping

SetNoDevice sets the NoDevice field's value.

SetVirtualName

func (s *BlockDeviceMapping) SetVirtualName(v string) *BlockDeviceMapping

SetVirtualName sets the VirtualName field's value.

String

func (s BlockDeviceMapping) String() string

String returns the string representation

On this page: