summaryrefslogtreecommitdiff
path: root/lib/oxidized/input
diff options
context:
space:
mode:
authorSaku Ytti <saku@ytti.fi>2018-06-22 19:37:52 +0300
committerSaku Ytti <saku@ytti.fi>2018-06-22 19:37:52 +0300
commitd83eb5dd21c259bb2f81aa2cb1a92ed00a80c9a7 (patch)
treea753f89669654f570196018ba196725015d281da /lib/oxidized/input
parent428708ef376884c3dc35aee1951cb8e1c55fac9f (diff)
parent04ffb2c68ac7f069bd9f33f39c77095c979aaec1 (diff)
Merge branch 'refactor-smells'
Diffstat (limited to 'lib/oxidized/input')
-rw-r--r--lib/oxidized/input/ssh.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/oxidized/input/ssh.rb b/lib/oxidized/input/ssh.rb
index 82335f9..01f7063 100644
--- a/lib/oxidized/input/ssh.rb
+++ b/lib/oxidized/input/ssh.rb
@@ -24,7 +24,7 @@ module Oxidized
@log = File.open(Oxidized::Config::Log + "/#{@node.ip}-ssh", 'w') if Oxidized.config.input.debug?
Oxidized.logger.debug "lib/oxidized/input/ssh.rb: Connecting to #{@node.name}"
- @ssh = Net::SSH.start(@node.ip, @node.auth[:username], get_ssh_opts)
+ @ssh = Net::SSH.start(@node.ip, @node.auth[:username], make_ssh_opts)
unless @exec
shell_open @ssh
begin
@@ -117,13 +117,13 @@ module Oxidized
end
end
- def get_ssh_opts
+ def make_ssh_opts
ssh_opts = {
port: (vars(:ssh_port) || 22).to_i,
paranoid: secure,
keepalive: true,
password: @node.auth[:password], timeout: Oxidized.config.timeout,
- number_of_password_prompts: 0
+ number_of_password_prompts: 0
}
auth_methods = vars(:auth_methods) || %w(none publickey password)