Skip to content

Commit 10f7947

Browse files
author
Will Miller
committed
Set boot order to hard drive, then network
Also, set power toggles for virsh.
1 parent 0d9b954 commit 10f7947

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

templates/vm.xml.j2

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,14 @@
33
<memory>{{ libvirt_vm_memory_mb | int * 1024 }}</memory>
44
<vcpu>{{ libvirt_vm_vcpus }}</vcpu>
55
<clock sync="localtime"/>
6+
<on_poweroff>destroy</on_poweroff>
7+
<on_reboot>restart</on_reboot>
8+
<on_crash>destroy</on_crash>
69
<os>
710
<type arch='{{ libvirt_vm_arch }}'{% if libvirt_vm_machine is not none %} machine='{{ libvirt_vm_machine }}'{% endif %}>hvm</type>
811
<bootmenu enable='no'/>
12+
<boot dev='hd'/>
13+
<boot dev='network'/>
914
<bios useserial='yes'/>
1015
</os>
1116
<cpu{% if libvirt_vm_cpu_mode is not none %} mode='{{ libvirt_vm_cpu_mode }}'{% endif %}>

0 commit comments

Comments
 (0)