progress on vm_template

This commit is contained in:
2022-10-24 22:53:50 +13:00
parent 09d6c93224
commit 8daf2d1ff8
4 changed files with 32 additions and 24 deletions

View File

@ -1,5 +1,5 @@
<domain type='kvm'>
<name>{{ vm_name_prefix }}{{ vm_number }}</name>
<name>{{ vm_name }}</name>
<metadata>
<libosinfo:libosinfo xmlns:libosinfo="http://libosinfo.org/xmlns/libvirt/domain/1.0">
<libosinfo:os id="http://archlinux.org/archlinux/rolling"/>
@ -14,7 +14,7 @@
<os>
<type arch={{ vm_machine_arch }} machine={{ vm_machine_type }}>hvm</type>
<loader readonly='yes' secure='yes' type='pflash'>/usr/share/edk2-ovmf/x64/OVMF_CODE.secboot.fd</loader>
<nvram template=/usr/share/edk2-ovmf/x64/OVMF_VARS.fd>{{ fw_vars_pool_dir }}/{{ vm_name_prefix }}{{ vm_number }}_VARS.fd</nvram>
<nvram template=/usr/share/edk2-ovmf/x64/OVMF_VARS.fd>{{ firmware_vhd_pool_dir }}/{{ vm_name }}_VARS.fd</nvram>
<boot dev='hd'/>
</os>
<features>
@ -42,13 +42,13 @@
<emulator>/usr/bin/qemu-system-x86_64</emulator>
<disk type='file' device='disk'>
<driver name='qemu' type='qcow2'/>
<source file='{{ root_vhd_pool_dir }}/{{ vm_name_prefix }}{{ vm_number }}_vda.qcow2'/>
<source file='{{ root_vhd_pool_dir }}/{{ vm_name }}_vda.qcow2'/>
<target dev='vda' bus='virtio'/>
<boot order='1'/>
</disk>
<disk type='file' device='disk'>
<driver name='qemu' type='qcow2'/>
<source file='{{ root_vhd_pool_dir }}/{{ vm_name_prefix }}{{ vm_number }}_vdb.qcow2'/>
<source file='{{ containers_vhd_pool_dir }}/{{ vm_name }}_vdb.qcow2'/>
<target dev='vdb' bus='virtio'/>
</disk>
<controller type='usb' index='0' model='qemu-xhci' ports='15'/>