lib/fog/arubacloud/compute.rb in fog-arubacloud-0.0.5 vs lib/fog/arubacloud/compute.rb in fog-arubacloud-0.0.6
- old
+ new
@@ -17,10 +17,17 @@
PRO_HV = 1
PRO_VMW = 2
PRO_HV_LC = 3
SMART = 4
+ SNAPOPTYPE = {
+ "Create" => "1",
+ "Delete" => "2",
+ "Restore" => "3",
+ "List" => "4"
+ }
+
recognizes :url
requires :arubacloud_username, :arubacloud_password
# Models
model_path 'fog/arubacloud/compute/models'
@@ -57,10 +64,11 @@
request :purchase_ip
request :remove_ip
request :get_purchased_ip_addresses
request :get_hypervisors
request :reinitialize_vm
+ request :list_snapshot
request :create_snapshot
request :apply_snapshot
request :delete_snapshot
request :archive_vm
request :restore_vm
@@ -123,10 +131,9 @@
:http_method => :post,
:method => method_name,
:body => Fog::JSON.encode(body)
}
response = nil
-
if benchmark
time = Benchmark.realtime {
response = _request(options)
}
Fog::Logger.debug("#{options[:method]} took: #{time}")