mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
progress.
This commit is contained in:
parent
4308d7d627
commit
0b2a865cfc
4 changed files with 8 additions and 3 deletions
|
@ -45,6 +45,8 @@ module Fog
|
|||
image_name,
|
||||
zone_name,
|
||||
machine_type)
|
||||
|
||||
p data
|
||||
service.servers.merge_attributes()
|
||||
end
|
||||
|
||||
|
|
|
@ -24,7 +24,12 @@ module Fog
|
|||
else
|
||||
data = service.get_server(identity, zone).body
|
||||
end
|
||||
new(data)
|
||||
|
||||
if data["code"] != 200
|
||||
nil
|
||||
else
|
||||
new(data)
|
||||
end
|
||||
rescue Excon::Errors::NotFound
|
||||
nil
|
||||
end
|
||||
|
|
|
@ -24,7 +24,6 @@ module Fog
|
|||
body_object = {
|
||||
'name' => server_name,
|
||||
'image' => @api_url + @project + "/global/images/#{image_name}",
|
||||
'zone' => @api_url + @project + "/zones/#{zone_name}",
|
||||
'machineType' => @api_url + @project + "/global/machineTypes/#{machine_name}",
|
||||
'networkInterfaces' => [{
|
||||
'network' => @api_url + @project + "/global/networks/#{network_name}"
|
||||
|
|
|
@ -10,6 +10,5 @@ Shindo.tests("Fog::Compute[:google] | server model", ['google']) do
|
|||
test('#destroy') do
|
||||
@instance.destroy
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue