aboutsummaryrefslogtreecommitdiff
path: root/lib/leap_cli/commands/vagrant.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/leap_cli/commands/vagrant.rb')
-rw-r--r--lib/leap_cli/commands/vagrant.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/leap_cli/commands/vagrant.rb b/lib/leap_cli/commands/vagrant.rb
index 587e5e1..07bb863 100644
--- a/lib/leap_cli/commands/vagrant.rb
+++ b/lib/leap_cli/commands/vagrant.rb
@@ -37,12 +37,13 @@ module LeapCli; module Commands
private
def vagrant_command(cmd, args)
+ assert_config! 'provider.vagrant.network'
create_vagrant_file
nodes = manager.filter(args)[:local => true].field(:name)
if nodes.any?
execute "cd #{File.dirname(Path.named_path(:vagrantfile))}; vagrant #{cmd} #{nodes.join(' ')}"
else
- bail! "No nodes found"
+ bail! "No nodes found. This command only works on nodes with ip_address in the network #{manager.provider.vagrant.network}"
end
end