+pae = machine_type.pae
+acpi = machine_type.acpi
+apic = machine_type.apic
+
+vif = []
+
+disk = []
+
+if machine_type.hvm:
+ codepath = 'hvm'
+else:
+ codepath = 'paravm'
+
+if 'mirror' in locals(): #Installer
+ disk.append('phy:/dev/xenvg/d_foobar4_hda,hdb,r')
+
+ kernel = '/boot/vmlinuz-2.6.24-19-xen' #From hardy
+ ramdisk = '/boot/initrd.img-2.6.24-19-xen'
+
+ if not machine.nics:
+ raise RuntimeError('You must have a nic to autoinstall')
+ n = machine.nics[0]
+ extra = 'ro noresume'
+ extra += ' ip=%s::18.181.0.1:255.255.0.0:%s:eth0:off' % (n.ip, machine.name)
+ extra += ' mirror=%s dist=%s' % (mirror, dist)
+ extra += ' imagesize=%s' % imagesize
+ #extra += ' noinstall'
+ root = '/dev/hdb1'
+ codepath = None
+elif 'cdrom_image' in locals():
+ check(re.match('^[A-Za-z0-9][A-Za-z0-9_.-]*$', cdrom_image))
+ disk.append('file:/srv/images/' + cdrom_image + '.iso,hdc:cdrom,r')
+ boot = 'd'
+ codepath = 'hvm'
+
+if codepath == 'hvm':