Skip to content

Commit d8b6463

Browse files
committed
support hvm
initial support for supplementalCreateObjectOptions
1 parent 4949183 commit d8b6463

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

lib/softlayer/VirtualServerOrder.rb

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,10 @@ class VirtualServerOrder
108108
# Corresponds to +primaryBackendNetworkComponent.networkVlan.id+ in the +createObject+ documentation
109109
attr_accessor :user_metadata
110110

111+
# Hash, supplemental options - See https://sldn.softlayer.com/reference/datatypes/SoftLayer_Virtual_Guest_SupplementalCreateObjectOptions
112+
# Corresponds to +supplementalCreateObjectOptions+ in the +createObject+ documentation
113+
attr_accessor :supplementalCreateObjectOptions
114+
111115
# Create a new order that works through the given client connection
112116
def initialize (client = nil)
113117
@softlayer_client = client || Client.default_client
@@ -170,11 +174,12 @@ def virtual_guest_template
170174
template['primaryNetworkComponent'] = { "networkVlan" => { "id" => @public_vlan_id.to_i } } if @public_vlan_id
171175
template['primaryBackendNetworkComponent'] = { "networkVlan" => {"id" => @private_vlan_id.to_i } } if @private_vlan_id
172176
template['sshKeys'] = @ssh_key_ids.collect { |ssh_key_id| {'id'=> ssh_key_id.to_i } } if @ssh_key_ids
177+
template['supplementalCreateObjectOptions'] = @supplementalCreateObjectOptions if @supplementalCreateObjectOptions
173178

174179
if @image_template
175-
template['blockDeviceTemplateGroup'] = {"globalIdentifier" => @image_template.global_id}
180+
template['blockDeviceTemplateGroup'] = {"globalIdentifier" => @image_template.global_id}
176181
elsif @os_reference_code
177-
template['operatingSystemReferenceCode'] = @os_reference_code
182+
template['operatingSystemReferenceCode'] = @os_reference_code
178183
end
179184

180185
if @disks && !@disks.empty?

0 commit comments

Comments
 (0)