{% trans "While the VM runs, most settings here apply at its next start." %}
{% endif %}
{% if instance.guest_agent_ready %}
{% include 'instances/info_tab.html' %}
{% endif %}
{% if request.user.is_superuser %}
{# the devices the VM tries in turn when it starts, and those it does not try; each moves on its own #}
{% trans "Boot order" %}
{% trans "When the VM starts it tries these devices in turn and boots from the first that works." %}
{% trans "Startup settings" %}
{# its CD-ROM drives, then its disks as list rows; the forms are those of the actions #}
{% if instance.status != 5 %}
{% bs_icon 'lock' %} {% trans "The VM is running: CD-ROM drives added now use the USB or SCSI bus. Shut it down to detach a SATA or IDE CD-ROM drive, or to detach or delete disks." %}
{% endif %}
{% trans "Removable media" %}
{# the pools are read again: an ISO image copied to one by hand is listed then #}
{% include 'add_instance_cdrom.html' %}
{% for cd in instance.media %}
{% empty %}
{% trans "The VM has no CD-ROM drive." %}
{% endfor %}
{% trans "Disks" %} · {{ instance.config_disks|length }}
{% include 'add_instance_volume.html' %}
{% for disk in instance.config_disks %}
{% bs_icon 'device-hdd' %} {{ disk.dev }}
{{ disk.bus }} · {{ disk.format }}
{% if disk.storage is None %}
{% trans "Error getting disk info" %}
{% else %}
{% widthratio disk.used disk.size 100 as used_percent %}
{# a qcow2 file's metadata can take it past its capacity: the bar stops full #}
{% if used_percent|add:0 > 100 %}{% widthratio 100 1 1 as used_percent %}{% endif %}
{% trans "Capacity" %} {{ disk.size|filesizeformat }}{% blocktrans with used=disk.used|filesizeformat %}{{ used }} used{% endblocktrans %}
{% trans "Storage pool" %}{{ disk.storage }}
{% trans "Source" %}: {{ disk.path }}
{% endif %}
{% if request.user.is_superuser %}{% include 'instances/move_disk.html' with id=forloop.counter0 %}{% endif %}
{% trans "Device details" %}
{% trans "Cache" %}
{{ disk.cache }}
{% trans "IO mode" %}
{{ disk.io }}
{% trans "Discard" %}
{{ disk.discard }}
{% trans "Detect zeroes" %}
{{ disk.detect_zeroes }}
{% trans "Serial" %}
{{ disk.serial|default:"—" }}
{% trans "Read-only" %}
{{ disk.readonly|yesno }}
{% trans "Shareable" %}
{{ disk.shareable|yesno }}
{% endfor %}
{% if instance.pcie_slots %}
{# a PCIe machine gives each virtio disk and network device a slot; a running VM gets no new one #}
{% with total=instance.pcie_slots.0 free=instance.pcie_slots.1 next=instance.config_pcie_slots %}
{% blocktrans %}PCIe slots: {{ free }} free of {{ total }}{% endblocktrans %}{% if next and next.1 != free %} · {% blocktrans with next_free=next.1 %}{{ next_free }} free from the next start{% endblocktrans %}{% endif %}
{% if request.user.is_superuser %}
{% endif %}
{% endwith %}
{% endif %}
{# a row per NIC in one list, as the disks; its QoS limits fold out like its device details #}
{% trans "Network devices" %} ({{ instance.config_networks|length }})
{% include 'add_instance_network_block.html' %}
{% for network in instance.config_networks %}
{# the NIC as a cable from the VM to its source: solid while its link is up, dashed while down #}
eth{{ forloop.counter0 }}
{{ network.nic|default:"—" }}
{# a NIC that is a host device is changed in the XML editor #}
{% if network.type != "hostdev" %}
{% endif %}
{% if network.type != "hostdev" %}
{% endif %}
{% if network.ipv4 %}{{ network.ipv4|join:", " }}{% else %}{% trans "No IPv4 address known" %}{% endif %}
{{ network.model|default:"—" }}, {{ network.mac }}{% if network.filterref %}, {% blocktrans with filter=network.filterref %}filter {{ filter }}{% endblocktrans %}{% endif %}{% if network.inbound or network.outbound %}, {% trans "bandwidth limited" %}{% endif %}
{% if network.type == 'direct' %}
{% trans "In most configurations, macvtap does not work for host to guest network communication" %}
{% endif %}
{% trans "Device details" %}
{% trans "Type" %}
{{ network.type }}
{% trans "Host device" %}
{{ network.target|default:_("no target") }}
{% trans "IPv6" %}
{{ network.ipv6|join:", "|default:_("unknown") }}
{% if network.inbound or network.outbound %}
{% trans "QoS limits" %}: {% if network.inbound and network.outbound %}{% trans "inbound, outbound" %}{% elif network.inbound %}{% trans "inbound" %}{% else %}{% trans "outbound" %}{% endif %}
{% if network.inbound %}{% include 'instances/nic_qos_form.html' with nic=forloop.counter0 direction="inbound" limit=network.inbound %}{% endif %}
{% if network.outbound %}{% include 'instances/nic_qos_form.html' with nic=forloop.counter0 direction="outbound" limit=network.outbound %}{% endif %}
{% trans "Average and peak are in KiB/s, burst in KiB. A running VM gets a change after it is powered off and on." %}
{% endif %}
{# the dialogs of Edit and Add QoS #}
{% if network.type != "hostdev" %}
{% endif %}
{% empty %}
{% trans "The VM has no network device." %}
{% endfor %}
{% if show_hostdevs %}
{% trans "Devices of the host given to the VM. The VM starts only on a host that has them; it is not migrated while it has them, and its clones get none." %}
{% if request.user.is_superuser %}
{# the add forms come when the tab opens: their choices scan every VM of the host #}
{% if device.address %}{% blocktrans with bus=device.address.0 device=device.address.1 %}Its address {{ bus }}/{{ device }}{% endblocktrans %}{% else %}{% trans "Its model: any device of it" %}{% endif %}
{% if device.now %}{% blocktrans with bus=device.now.0 device=device.now.1 %}Has {{ bus }}/{{ device }}{% endblocktrans %}{% else %}–{% endif %}
{% if device.next %}{% trans "Yes" %}{% else %}{% trans "No" %}{% endif %}
{% if device.now %}{% trans "Has it" %}{% else %}–{% endif %}
{% if device.next %}{% trans "Yes" %}{% else %}{% trans "No" %}{% endif %}
{% if request.user.is_superuser %}
{% endif %}
{% endfor %}
{% endif %}
{% for device in other_hostdevs %}
{% if device.type == "nic" %}{% trans "Network interface" %}{% else %}{{ device.type|upper }}{% endif %} {{ device.address }}{% if device.now and device.next %}{% trans "running VM and next start" %}{% elif device.now %}{% trans "running VM only" %}{% else %}{% trans "next start only" %}{% endif %}; {% trans "changed in the XML editor" %}
{% endfor %}
{% if not usb_hostdevs and not pci_hostdevs and not other_hostdevs %}
{% trans "The VM has no host devices." %}
{% endif %}
{% endif %}
{% if instance.status != 5 %}
{% trans "This is the definition for the VM's next start; a saved change applies then." %}
{% endif %}
{% trans "Review the XML change" %}
{% trans "The XML is the same as the VM's definition; there is nothing to save." %}
{% trans "Instance owners" %}
{% include 'add_instance_owner_block.html' %}
{% trans "Every owner can power the VM and open its console. A new owner has no other right until it is given one." %}
{% if userinstance.is_change or userinstance.is_delete %}
{% if userinstance.is_change %}{% trans "Change settings" %}{% endif %}{% if userinstance.is_change and userinstance.is_delete %} · {% endif %}{% if userinstance.is_delete %}{% trans "Delete the VM" %}{% endif %}{% if userinstance.is_change and userinstance.is_vnc %} · {% trans "Change console settings" %}{% endif %}
{% else %}
{% trans "Power and console only" %}
{% endif %}