multi ephemeral support
This commit adds the ability to specify multiple ephemeral disks through the
bootfromvolume extension.
diff --git a/openstack/compute/v2/extensions/bootfromvolume/requests.go b/openstack/compute/v2/extensions/bootfromvolume/requests.go
index c8edee0..dceff3d 100644
--- a/openstack/compute/v2/extensions/bootfromvolume/requests.go
+++ b/openstack/compute/v2/extensions/bootfromvolume/requests.go
@@ -15,6 +15,7 @@
Volume SourceType = "volume"
Snapshot SourceType = "snapshot"
Image SourceType = "image"
+ Blank SourceType = "blank"
)
// BlockDevice is a structure with options for booting a server instance
@@ -32,6 +33,9 @@
// and "local".
DestinationType string `json:"destination_type"`
+ // GuestFormat [optional] specifies the format of the block device.
+ GuestFormat string `json:"guest_format"`
+
// SourceType [required] must be one of: "volume", "snapshot", "image".
SourceType SourceType `json:"source_type"`
@@ -82,6 +86,9 @@
if bd.DestinationType != "" {
blockDevice[i]["destination_type"] = bd.DestinationType
}
+ if bd.GuestFormat != "" {
+ blockDevice[i]["guest_format"] = bd.GuestFormat
+ }
}
serverMap["block_device_mapping_v2"] = blockDevice