{% extends "base.html" %} {% load i18n %} {% load static %} {% load bootstrap_icons %} {% block title %}{% trans "Interfaces" %} - {{ compute.name }}{% endblock %} {% block page_heading %}{{ compute.name }} - {% trans "Interfaces" %}{% endblock page_heading %} {% block page_heading_extra %} {% if changeable %}{% include 'create_iface_block.html' %}{% endif %} {% endblock page_heading_extra %} {% block content %} {% include "computes/host_nav.html" with section="interfaces" %} {% if changeable is False %}{% include 'interfaces_unchangeable.html' %}{% endif %} {% if not ifaces_all %}
{% bs_icon 'exclamation-triangle' %} {% trans "libvirt lists no interfaces of this host." %}
{% else %} {# a card per interface, as the networks', under its type; a type's heading shows while any of its cards does #} {% for title, ifaces in iface_groups %}{% if ifaces %}

{{ title }} {{ ifaces|length }}

{% for iface in ifaces %}
{{ iface.name }} {% include "link_badge.html" with link=iface.link %}
    {# the same rows on every card of a type, a dash for what is not known #}
  • {% trans "MAC" %} {{ iface.mac|default:"–" }}
  • {% trans "MTU" %}{{ iface.mtu|default:"–" }}
  • {% if iface.type == "ethernet" or iface.type == "bond" %}
  • {% trans "Speed" %}{% if iface.speed %}{{ iface.speed }} Mb/s{% else %}–{% endif %}
  • {% endif %} {% if iface.type != "ethernet" %}
  • {% trans "Members" %} {% if iface.members %}{% blocktrans count counter=iface.members|length %}{{ counter }} reported{% plural %}{{ counter }} reported{% endblocktrans %}{% else %}–{% endif %}
  • {% endif %}
  • {% trans "Used by" %} {% for net in iface.networks %}{% blocktrans %}network {{ net }}{% endblocktrans %}{% if not forloop.last %}, {% endif %}{% empty %}–{% endfor %}
{% endfor %}
{% endif %}{% endfor %}
{% endif %} {% endblock %} {% block script %} {% if ifaces_all %}{% endif %} {% endblock %}