From cf4ab7752cd7c6141f2da0a7491c9f1842c88f09 Mon Sep 17 00:00:00 2001 From: Elvin Efendi Date: Thu, 2 Jun 2016 20:24:18 +0200 Subject: some debug statements --- lib/oxidized/input/cli.rb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'lib/oxidized/input/cli.rb') diff --git a/lib/oxidized/input/cli.rb b/lib/oxidized/input/cli.rb index 731b459..fc7f426 100644 --- a/lib/oxidized/input/cli.rb +++ b/lib/oxidized/input/cli.rb @@ -17,10 +17,15 @@ module Oxidized end def connect_cli - @post_login.each { |command, block| block ? block.call : (cmd command) } + Oxidized.logger.debug "lib/oxidized/input/cli.rb: Running post_login commands at #{node.name}" + @post_login.each do |command, block| + Oxidized.logger.debug "lib/oxidized/input/cli.rb: Running post_login command: #{command.inspect}, block: #{block.inspect} at #{node.name}" + block ? block.call : (cmd command) + end end def disconnect_cli + Oxidized.logger.debug "lib/oxidized/input/cli.rb Running pre_logout commands at #{node.name}" @pre_logout.each { |command, block| block ? block.call : (cmd command, nil) } end -- cgit v1.2.1