summaryrefslogtreecommitdiffstats
path: root/func/minion/modules/virt.py
diff options
context:
space:
mode:
Diffstat (limited to 'func/minion/modules/virt.py')
-rw-r--r--func/minion/modules/virt.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/func/minion/modules/virt.py b/func/minion/modules/virt.py
index ebc0a1c..2c68ab4 100644
--- a/func/minion/modules/virt.py
+++ b/func/minion/modules/virt.py
@@ -200,6 +200,15 @@ class Virt(func_module.FuncModule):
"/etc/xen/auto"
]
else:
+ # When using KVM, we need to make sure the autostart
+ # directory exists
+ mkdir_args = [
+ "/bin/mkdir",
+ "-p",
+ "/etc/libvirt/qemu/autostart"
+ ]
+ sub_process.call(mkdir_args,shell=False,close_fds=True)
+
# We aren't using virsh autostart because we want
# the command to work even when the VM isn't running
autostart_args = [