summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/oxidized/input/ssh.rb3
-rw-r--r--lib/oxidized/node.rb2
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/oxidized/input/ssh.rb b/lib/oxidized/input/ssh.rb
index ccc3d1c..f881ff1 100644
--- a/lib/oxidized/input/ssh.rb
+++ b/lib/oxidized/input/ssh.rb
@@ -118,6 +118,7 @@ module Oxidized
end
def make_ssh_opts
+ secure = Oxidized.config.input.ssh.secure?
ssh_opts = {
port: (vars(:ssh_port) || 22).to_i,
paranoid: secure,
@@ -131,7 +132,7 @@ module Oxidized
if proxy_host = vars(:ssh_proxy)
proxy_command = "ssh "
- proxy_command += "-o StrictHostKeyChecking=no " unless Oxidized.config.input.ssh.secure?
+ proxy_command += "-o StrictHostKeyChecking=no " unless secure
proxy_command += "#{proxy_host} -W %h:%p"
proxy = Net::SSH::Proxy::Command.new(proxy_command)
ssh_opts[:proxy] = proxy
diff --git a/lib/oxidized/node.rb b/lib/oxidized/node.rb
index c3a6885..9dfeb19 100644
--- a/lib/oxidized/node.rb
+++ b/lib/oxidized/node.rb
@@ -223,7 +223,7 @@ module Oxidized
value
end
- def git_type
+ def git_type opt
type = opt[:output] || Oxidized.config.output.default
return nil unless type[0..2] == "git"
type