Check for VM accessibility in ssh_config

This commit is contained in:
Mitchell Hashimoto 2011-08-28 20:41:51 -07:00
parent c569c8b697
commit b3dc6ba7d0
1 changed files with 1 additions and 0 deletions

View File

@ -8,6 +8,7 @@ module Vagrant
raise Errors::MultiVMTargetRequired, :command => "ssh_config" if target_vms.length > 1 raise Errors::MultiVMTargetRequired, :command => "ssh_config" if target_vms.length > 1
vm = target_vms.first vm = target_vms.first
raise Errors::VMNotCreatedError if !vm.created? raise Errors::VMNotCreatedError if !vm.created?
raise Errors::VMInaccessible if !vm.vm.accessible?
# We need to fix the file permissions of the key if they aren't set # We need to fix the file permissions of the key if they aren't set
# properly, otherwise if the user attempts to SSH in, it won't work! # properly, otherwise if the user attempts to SSH in, it won't work!