<!--
You can load this machine definition into libvirt using:
	sudo virsh define openbsdw.xml
-->

<domain type='kvm'>
  <name>@@NAME@@</name>
  <memory unit='KiB'>393216</memory>
  <currentMemory unit='KiB'>393216</currentMemory>
  <vcpu placement='static'>1</vcpu>
  <os>
    <type arch='x86_64'>hvm</type>
    <boot dev='hd'/>
  </os>
   <cpu mode='host-model' check='partial'/>
  <clock offset='utc'>
    <timer name='rtc' tickpolicy='catchup'/>
    <timer name='pit' tickpolicy='delay'/>
    <timer name='hpet' present='no'/>
  </clock>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>restart</on_crash>
  <devices>
  	<emulator>/usr/bin/qemu-system-x86_64</emulator>
    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2'/>
      <source file='@@POOLSPACE@@/@@NAME@@.qcow2'/>
      <target dev='vda' bus='virtio'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    </disk>
    <controller type='usb' index='0'>
    </controller>
    <controller type='virtio-serial' index='0'>
    </controller>
    <!--OpenBSD uses NFS mount this filesystem is defined here just to hack some part of testing script to work-->
    <filesystem type='mount' accessmode='squash'>
      <source dir='@@TESTINGDIR@@'/>
      <target dir='testing'/>
    </filesystem>
    <interface type='network'>
      <mac address='12:00:00:64:64:45'/>
      <source network='192_1_2'/>
      <model type='virtio'/>
    </interface>
    <interface type='network'>
      <mac address='12:00:00:ab:cd:ff'/>
      <source network='192_0_1'/>
      <model type='virtio'/>
    </interface>
    <interface type='network'>
      <source network='swandefault'/>
      <model type='virtio'/>
    </interface>
    <serial type='pty'>
      <target type='isa-serial' port='0'>
        <model name='isa-serial'/>
      </target>
    </serial>
    <console type='pty'>
      <target type='serial' port='0'/>
    </console>
    <input type='mouse' bus='ps2'/>
    <input type='keyboard' bus='ps2'/>
    <memballoon model='virtio'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
    </memballoon>
  </devices>
</domain>
