mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
use a hash not nil for default scp_options
This commit is contained in:
parent
b9198da1f7
commit
a840dd7224
7 changed files with 7 additions and 7 deletions
|
@ -200,7 +200,7 @@ module Fog
|
|||
Fog::SSH.new(public_ip_address, username, options).run(commands)
|
||||
end
|
||||
|
||||
def scp(local_path, remote_path, scp_options = nil)
|
||||
def scp(local_path, remote_path, scp_options = {})
|
||||
requires :public_ip_address, :username
|
||||
|
||||
options = {}
|
||||
|
|
|
@ -128,7 +128,7 @@ module Fog
|
|||
Fog::SSH.new(ips.first['address'], username, options).run(commands)
|
||||
end
|
||||
|
||||
def scp(local_path, remote_path, scp_options = nil)
|
||||
def scp(local_path, remote_path, scp_options = {})
|
||||
requires :ips, :username
|
||||
|
||||
options = {}
|
||||
|
|
|
@ -78,7 +78,7 @@ module Fog
|
|||
Fog::SSH.new(ip['ip'], username, options).run(commands)
|
||||
end
|
||||
|
||||
def scp(local_path, remote_path, scp_options = nil)
|
||||
def scp(local_path, remote_path, scp_options = {})
|
||||
requires :ip, :username
|
||||
|
||||
options = {}
|
||||
|
|
|
@ -120,7 +120,7 @@ module Fog
|
|||
Fog::SSH.new(public_ip_address, username, options).run(commands)
|
||||
end
|
||||
|
||||
def scp(local_path, remote_path, scp_options = nil)
|
||||
def scp(local_path, remote_path, scp_options = {})
|
||||
requires :public_ip_address, :username
|
||||
|
||||
options = {}
|
||||
|
|
|
@ -110,7 +110,7 @@ module Fog
|
|||
Fog::SSH.new(addresses.first, username, options).run(commands)
|
||||
end
|
||||
|
||||
def scp(local_path, remote_path, scp_options = nil)
|
||||
def scp(local_path, remote_path, scp_options = {})
|
||||
requires :addresses, :username
|
||||
|
||||
options = {}
|
||||
|
|
|
@ -151,7 +151,7 @@ module Fog
|
|||
end
|
||||
end
|
||||
|
||||
def scp(local_path, remote_path, scp_options = nil)
|
||||
def scp(local_path, remote_path, scp_options = {})
|
||||
raise 'Not Implemented'
|
||||
# requires :addresses, :username
|
||||
#
|
||||
|
|
|
@ -45,7 +45,7 @@ module Fog
|
|||
@options = { :paranoid => false }.merge(options)
|
||||
end
|
||||
|
||||
def upload(local_path, remote_path, scp_options = nil)
|
||||
def upload(local_path, remote_path, scp_options = {})
|
||||
begin
|
||||
Net::SCP.start(@address, @username, @options) do |scp|
|
||||
scp.upload!(local_path, remote_path, scp_options) do |ch, name, sent, total|
|
||||
|
|
Loading…
Add table
Reference in a new issue