mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
[bbg] provide for using ssh_key when calling create_block
This commit is contained in:
parent
961a333fd0
commit
45fa630386
1 changed files with 6 additions and 4 deletions
|
@ -8,19 +8,21 @@ module Fog
|
|||
# * product_id<~Integer> - Id of product to create block with
|
||||
# * template_id<~Integer> - Id of template to create block with
|
||||
# * name<~String> - Name of block
|
||||
# * password<~String> - Password for block
|
||||
# * options<~Hash>:
|
||||
# * password<~String> - Password for block
|
||||
# or
|
||||
# * ssh_key<~String> - ssh public key
|
||||
#
|
||||
# ==== Returns
|
||||
# * response<~Excon::Response>:
|
||||
# * body<~Hash>:
|
||||
# TODO
|
||||
def create_block(product_id, template_id, name, password)
|
||||
def create_block(product_id, template_id, name, options = {})
|
||||
data = {
|
||||
'name' => name,
|
||||
'password' => password,
|
||||
'product' => product_id,
|
||||
'template' => template_id
|
||||
}
|
||||
}.merge!(options)
|
||||
|
||||
request(
|
||||
:body => data.to_json,
|
||||
|
|
Loading…
Add table
Reference in a new issue