From 345ee35e16f418da5e54c158ea1a64d958b34c39 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Wed, 14 Dec 2011 23:35:46 -0800 Subject: [PATCH] When import recovers, don't validate when calling destroy --- lib/vagrant/action/vm/import.rb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/vagrant/action/vm/import.rb b/lib/vagrant/action/vm/import.rb index 971a9203e..07806831d 100644 --- a/lib/vagrant/action/vm/import.rb +++ b/lib/vagrant/action/vm/import.rb @@ -30,8 +30,11 @@ module Vagrant if env[:vm].created? return if env["vagrant.error"].is_a?(Errors::VagrantError) - # Interrupted, destroy the VM - env[:action_runner].run(:destroy, env) + # Interrupted, destroy the VM. We note that we don't want to + # validate the configuration here. + destroy_env = env.clone + destroy_env[:validate] = false + env[:action_runner].run(:destroy, destroy_env) end end end