{% block basic %} {{ vm.name }} {{ vm.uuid }} {% if vm.virt_mode == 'hvm' and vm.devices['pci'].persistent() | list %} {{ vm.memory }} {% else %} {{ vm.maxmem }} {% endif %} {{ vm.memory }} {{ vm.vcpus }} {% endblock %} {% block cpu %} {% if vm.virt_mode != 'pv' %} {% endif %} {% endblock %} {% block os %} {% if vm.virt_mode == 'hvm' %} hvm hvmloader {% else %} {% if vm.virt_mode == 'pvh' %} hvm {% else %} linux {% endif %} {{ vm.storage.kernels_dir }}/vmlinuz {{ vm.storage.kernels_dir }}/initramfs {% endif %} {% if vm.kernel %} root=/dev/mapper/dmroot ro nomodeset console=hvc0 rd_NO_PLYMOUTH rd.plymouth.enable=0 plymouth.enable=0 {{ vm.kernelopts }} {% endif %} {% endblock %} {% block features %} {% if vm.virt_mode != 'pv' %} {% endif %} {% if vm.devices['pci'].persistent() | list and vm.features.get('pci-e820-host', True) %} {% endif %} {% endblock %} {% block clock %} {% if vm.virt_mode == 'hvm' %} {% set timezone = vm.features.check_with_template('timezone', 'localtime').lower() %} {% if timezone == 'localtime' %} {% elif timezone.isdigit() %} {% else %} {% endif %} {% else %} {% endif %} {% endblock %} {% block on %} destroy destroy destroy {% endblock %} {% block devices %} {% set i = 0 %} {# TODO Allow more volumes out of the box #} {% set dd = ['e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y'] %} {% for device in vm.block_devices %} {% if device.name == 'root' %} {% elif device.name == 'private' %} {% elif device.name == 'volatile' %} {% elif device.name == 'kernel' %} {% else %} {% set i = i + 1 %} {% endif %} {% if not device.rw %} {% endif %} {% if device.domain %} {% endif %} {% if device.script %}