summaryrefslogtreecommitdiff
path: root/lib/oxidized
diff options
context:
space:
mode:
Diffstat (limited to 'lib/oxidized')
-rw-r--r--lib/oxidized/input/ssh.rb5
-rw-r--r--lib/oxidized/worker.rb6
2 files changed, 9 insertions, 2 deletions
diff --git a/lib/oxidized/input/ssh.rb b/lib/oxidized/input/ssh.rb
index dc1eb27..6e86d13 100644
--- a/lib/oxidized/input/ssh.rb
+++ b/lib/oxidized/input/ssh.rb
@@ -29,11 +29,14 @@ module Oxidized
port: port.to_i,
paranoid: secure,
keepalive: true,
- auth_methods: %w(none publickey password keyboard-interactive),
password: @node.auth[:password], :timeout => Oxidized.config.timeout,
number_of_password_prompts: 0,
}
+ auth_methods = vars(:auth_methods) || %w(none publickey password)
+ ssh_opts[:auth_methods] = auth_methods
+ Oxidized.logger.info "AUTH METHODS::#{auth_methods}"
+
if proxy_host = vars(:ssh_proxy)
proxy_command = "ssh "
proxy_command += "-o StrictHostKeyChecking=no " unless secure
diff --git a/lib/oxidized/worker.rb b/lib/oxidized/worker.rb
index 7eaa888..692b060 100644
--- a/lib/oxidized/worker.rb
+++ b/lib/oxidized/worker.rb
@@ -80,7 +80,11 @@ module Oxidized
private
def is_cycle_finished?
- @jobs_done > 0 && @jobs_done % @nodes.count == 0
+ if @jobs_done > @nodes.count
+ true
+ else
+ @jobs_done > 0 && @jobs_done % @nodes.count == 0
+ end
end
def run_done_hook