summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorvarac <varacanero@zeromail.org>2016-01-19 20:05:22 +0100
committervarac <varacanero@zeromail.org>2016-01-19 22:35:37 +0100
commit45412d75d16189719c059c0368eca4bda75e6ff8 (patch)
treef44e451cf48a13f027c2ff48bcf3f1371a423374 /lib
parent935a5e884dc468da2b9ec724638f1c55a8f74e85 (diff)
[feat] Add 'leap debug' cmd
This will output node debug information by calling the bin/debug.sh script.
Diffstat (limited to 'lib')
-rw-r--r--lib/leap_cli/commands/debug.rb15
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/leap_cli/commands/debug.rb b/lib/leap_cli/commands/debug.rb
new file mode 100644
index 00000000..a969b752
--- /dev/null
+++ b/lib/leap_cli/commands/debug.rb
@@ -0,0 +1,15 @@
+module LeapCli; module Commands
+
+ desc 'Output debug information.'
+ long_desc 'The FILTER can be the name of a node, service, or tag.'
+ arg_name 'FILTER'
+ command [:debug, :d] do |c|
+ c.action do |global,options,args|
+ nodes = manager.filter!(args)
+ ssh_connect(nodes, connect_options(options)) do |ssh|
+ ssh.leap.debug
+ end
+ end
+ end
+
+end; end