[gogrid] cleanup

This commit is contained in:
geemus 2011-01-26 15:19:48 -08:00
parent 5d5c87d1ed
commit b968cf88a8
3 changed files with 6 additions and 6 deletions

View File

@ -6,8 +6,8 @@ Gem::Specification.new do |s|
## Leave these as is they will be modified for you by the rake gemspec task.
## If your rubyforge_project name is different, then edit it and comment out
## the sub! line in the Rakefile
s.name = 'phpfog-fog'
s.version = '0.4.1.3'
s.name = 'fog'
s.version = '0.4.1'
s.date = '2011-01-21'
s.rubyforge_project = 'fog'

View File

@ -11,7 +11,7 @@ module Fog
identity :id
attribute :name
attribute :image_id # id or name
attribute :image_id # id or name
attribute :ip
attribute :memory # server.ram
attribute :state
@ -55,11 +55,10 @@ module Fog
requires :name, :image_id, :ip, :memory
options = {
'isSandbox' => sandbox,
'server.ram' => memory,
'image' => image_id
}
options = options.reject {|key, value| value.nil?}
data = connection.grid_server_add(name, image, ip, options)
data = connection.grid_server_add(image, ip, name, memory, options)
merge_attributes(data.body)
true
end

View File

@ -18,13 +18,14 @@ module Fog
# * response<~Excon::Response>:
# * body<~Array>:
# TODO: docs
def grid_server_add(name, image, ip, options={})
def grid_server_add(image, ip, name, server_ram, options={})
request(
:path => 'grid/server/add',
:query => {
'image' => image,
'ip' => ip,
'name' => name,
'server.ram' => server_ram
}.merge!(options)
)
end