aboutsummaryrefslogtreecommitdiff
path: root/lib/leap_cli/commands/node.rb
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2013-03-14 00:20:41 -0700
committerelijah <elijah@riseup.net>2013-03-14 00:20:41 -0700
commit2fd87063c0f48b67cb53bba6d52d82a091be6a7b (patch)
tree8c5a98ee0336465466d6356ba1253fb2fdf0bf5d /lib/leap_cli/commands/node.rb
parent84d94fd879b70140bc8d3038d562f650b0e8fb70 (diff)
downloadleap_cli-2fd87063c0f48b67cb53bba6d52d82a091be6a7b.tar.gz
leap_cli-2fd87063c0f48b67cb53bba6d52d82a091be6a7b.tar.bz2
set hostname on `leap node init`
Diffstat (limited to 'lib/leap_cli/commands/node.rb')
-rw-r--r--lib/leap_cli/commands/node.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/leap_cli/commands/node.rb b/lib/leap_cli/commands/node.rb
index 7b929e0..8ebb5e8 100644
--- a/lib/leap_cli/commands/node.rb
+++ b/lib/leap_cli/commands/node.rb
@@ -52,13 +52,14 @@ module LeapCli; module Commands
node.command :init do |init|
init.switch 'echo', :desc => 'If set, passwords are visible as you type them (default is hidden)', :negatable => false
init.action do |global,options,args|
- assert! args.any?, 'You must specify a node-filter'
+ assert! args.any?, 'You must specify a FILTER'
finished = []
manager.filter!(args).each_node do |node|
ping_node(node)
save_public_host_key(node, global)
update_compiled_ssh_configs
ssh_connect(node, :bootstrap => true, :echo => options[:echo]) do |ssh|
+ ssh.set_hostname
ssh.install_authorized_keys
ssh.install_prerequisites
end