mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
Use builtin GracefulHalt action on halt
Updates the halt action to use the GracefulHalt builtin action.
If the GracefulHalt builtin action fails to properly transition
the state of the guest, it will use the HaltDomain action to
forcibly stop it.
This commit is contained in:
committed by
Darragh Bailey
parent
32f69c5361
commit
64d087d2f9
@@ -143,7 +143,11 @@ module VagrantPlugins
|
|||||||
next unless env2[:result]
|
next unless env2[:result]
|
||||||
|
|
||||||
# VM is running, halt it.
|
# VM is running, halt it.
|
||||||
b3.use HaltDomain
|
b3.use Call, GracefulHalt, :shutoff, :running do |env3, b4|
|
||||||
|
if !env3[:result]
|
||||||
|
b4.use HaltDomain
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user