diff --git a/lib/vagrant-hostmanager/hosts_file.rb b/lib/vagrant-hostmanager/hosts_file.rb index e7f0f80..d11f695 100644 --- a/lib/vagrant-hostmanager/hosts_file.rb +++ b/lib/vagrant-hostmanager/hosts_file.rb @@ -104,7 +104,7 @@ module VagrantPlugins machine.config.vm.networks.each do |network| key, options = network[0], network[1] ip = options[:ip] if key == :private_network - next if ip + break if ip end end ip || (machine.ssh_info ? machine.ssh_info[:host] : nil)