{% extends "layout.html" %} {% from "_partials/page_description.html" import page_description %} {% block title %}{{ image.primary_name }} - Images - pixie{% endblock %} {% block content %}

{{ image.primary_name }}

{% if image.orphan %}orphan blob {% elif not image.in_use %}unused {% else %}in use ({{ image.usage_count }}){% endif %}
{{ page_description('hdd-fill', 'One materialised image (identity = the disk content sha) with its derived artifacts and every live usage. The usage count is the refcount: delete is allowed only when it reaches zero.') }} {# ---- Artifacts / footprint ------------------------------------- #}
Artifacts
Content sha
{{ image.sha }}
{% if image.names %}
Catalog name(s)
{% for n in image.names %} {{ n }}{% if not loop.last %}, {% endif %} {% endfor %}
{% endif %}
Disk (raw + rootfs)
{{ image.disk_bytes | humanize_bytes }} · {{ blob_path }}
Boot (netboot bundle)
{% if image.boot_present %} {{ image.boot_bytes | humanize_bytes }} · {{ image.boot_bundle_name }} {% else %} not fetched — flash only, no nbdboot {% endif %}
Overlays
{{ image.overlays_bytes | humanize_bytes }}
Total on disk
{{ image.footprint_bytes | humanize_bytes }}
{# ---- Usages ---------------------------------------------------- #}
Usage ({{ image.usage_count }})

Machines bound {{ image.machines_count }}

{% if image.machines %}
{% for mu in image.machines %} {% endfor %}
MACBoot modeOverlay alias
{{ mu.mac }} {{ mu.boot_mode }} {% if mu.overlay_alias %}{{ mu.overlay_alias }}{% else %}ephemeral{% endif %}
{% else %}

No machine is bound to this image.

{% endif %}

NBD export (ephemeral, nbdkit)

{% if image.export_running %}

Serving on {% for p in image.export_ports %}:{{ p }} {% endfor %}(ephemeral nbdkit for this image's disk blob).

{% else %}

No ephemeral export running.

{% endif %}

Overlays (persistent, qemu-nbd) {{ image.overlays_total }}

{% if image.overlays_total %}

{{ image.overlays_running }} of {{ image.overlays_total }} serving — manage on Overlays.

{% else %}

No overlays.

{% endif %}
{# ---- Danger zone: guarded GC ----------------------------------- #}
Delete image (reclaim disk)
{% if image.in_use %}

Blocked: {{ image.usage_count }} live dependenc{{ 'y' if image.usage_count == 1 else 'ies' }} ({{ image.machines_count }} machine(s), {{ image.export_ports | length }} export(s), {{ image.overlays_total }} overlay(s)). Rebind those machines and reset the overlays first, then this frees {{ image.footprint_bytes | humanize_bytes }}.

{% else %}

Deletes the on-disk bytes (blobs/{{ image.sha[:12] }}/ — raw disk + rootfs), freeing {{ image.footprint_bytes | humanize_bytes }}, and clears the sha off {% if image.names %}its catalog entr{{ 'y' if image.names|length == 1 else 'ies' }} (Fetch re-materialises it){% else %}nothing (orphan blob){% endif %}.

{% endif %}
{% endblock %}