{% extends "base.html" %} {% load i18n %} {% load static %} {% load bootstrap_icons %} {% load operations %} {% block title %}{% trans "Computes" %}{% endblock %} {% block content %}
{% include 'create_comp_block.html' %} {% if computes|length > 1 %}{% trans "Balance" %}{% endif %} {% include 'search_block.html' %}

{% trans "Computes" %}

{% if not computes %}
{% bs_icon 'exclamation-triangle'%} {% trans "Warning" %}: {% trans "You don't have any computes" %}
{% else %} {# the totals of the hosts the panel reaches #}
{% bs_icon 'hdd-rack' %} {% trans "Hosts" %}
{{ totals.connected }} / {{ totals.hosts }}
{% trans "connected" %}
{% bs_icon 'server' %} {% trans "VMs" %}
{{ totals.running }} / {{ totals.vms }}
{% trans "running" %}
{% bs_icon 'cpu' %} {% trans "vCPUs given" %}
{{ totals.vcpus }}
{% blocktrans count counter=totals.cpus %}on {{ counter }} CPU{% plural %}on {{ counter }} CPUs{% endblocktrans %}
{% bs_icon 'memory' %} {% trans "Memory given" %}
{{ totals.assigned|filesizeformat }}
{% blocktrans with memory=totals.memory|filesizeformat %}of {{ memory }}{% endblocktrans %}
{% include 'common/tag_filter.html' %} {# position-relative: the hidden status texts are positioned within it, not the page #}
{% for compute in computes %} {% with given=compute.shown_capacity %} {% if given %} {% else %} {% endif %} {% endwith %} {% endfor %}
{% trans "Host" %} {% trans "VMs" %} {% trans "vCPUs" %} {% trans "Memory" %} {% trans "Actions" %}
{{ compute.name }} {% if compute.status is True %} {% trans "Connected" %} {% else %} {% trans "Not connected" %} {% endif %} {% if compute.maintenance %}{# ready once none of its VMs runs; while that is not known, only asked for #} {% if compute.shown_capacity and not compute.shown_capacity.active %}{% trans "In maintenance" %}{% else %}{% trans "Maintenance requested" %}{% endif %}{% endif %} {{ compute.connection_name }}
{{ compute.hostname }}
{% if compute.details %}
{{ compute.details }}
{% endif %} {% with tags=compute.tags.all %}{% if tags %}
{% include 'common/tag_badges.html' with tags=tags|slice:":3" more=tags|slice:"3:" filter=True %}
{% endif %}{% endwith %} {% if compute.status is not True %}
{{ compute.connection_error }}
{% endif %}
{{ given.vm_count }}
{% blocktrans with running=given.vms.running %}{{ running }} running{% endblocktrans %}
{% include "computes/capacity_vcpus.html" %} {% include "computes/capacity_memory.html" %} {% if compute.status is True %}{% trans "The capacity could not be read." %}{% else %}{% trans "No capacity while the host cannot be reached." %}{% endif %} {# fixed: the menu would be cut off by the table's scrolling box #}
{# table_filter.js shows it while no host matches #} {% endif %} {% endblock content %} {% block script %} {% job_panel_script job_resource %} {% endblock script %}