{# docker/container_detail.html — full detail page for one container #} {% extends "base.html" %} {% block title %}{{ name }} — Docker — Steward{% endblock %} {% block content %}
← All containers
{% if container is none %}
Container not found
No container named {{ name }} is currently reported for this host. It may have been removed, or the host agent hasn't reported recently.
{% else %} {# ── Header ──────────────────────────────────────────────────────────────── #}

{{ container.name }}

{% if container.health == 'healthy' %}healthy {% elif container.health == 'unhealthy' %}unhealthy {% elif container.health == 'starting' %}starting{% endif %}
{{ container.status }}{% if uptime %} · up {{ uptime }}{% endif %} {% if host %} · on {{ host.name }}{% endif %}
{# ── Facts grid ──────────────────────────────────────────────────────────── #} {% macro fact(label, value, colour="") %}
{{ label }}
{{ value }}
{% endmacro %}
{{ fact("CPU", "%.1f%%" | format(container.cpu_pct) if container.cpu_pct is not none else "—") }} {{ fact("Memory", "%.1f%%" | format(container.mem_pct) if container.mem_pct is not none else "—") }} {{ fact("Restarts", container.restart_count, "var(--orange)" if container.restart_count else "") }} {{ fact("Last exit", (container.exit_code ~ (" (OOM)" if container.oom_killed else "")) if container.exit_code is not none else "—", "var(--red)" if (container.exit_code is not none and container.exit_code != 0) else "") }} {{ fact("Net in", net_rx) }} {{ fact("Net out", net_tx) }} {{ fact("Block read", blk_read) }} {{ fact("Block write", blk_write) }}
{# ── Image / placement ───────────────────────────────────────────────────── #}
Image {{ container.image or "—" }} {% if container.compose_project %} Compose project{{ container.compose_project }} {% endif %} {% if container.service_name %} Swarm service{{ container.service_name }} {% endif %} {% if container.node_id %} Node{{ container.node_id }} {% endif %} {% if ports %} Ports {% for p in ports %}{{ p.host_port }}:{{ p.container_port }}/{{ p.protocol }}{% if not loop.last %}, {% endif %}{% endfor %} {% endif %}
{# ── Resource history (range-toggled) ────────────────────────────────────── #}

Resource history

{% include "_time_range.html" %}
Loading…
{# ── Lifecycle timeline ──────────────────────────────────────────────────── #}

Lifecycle

{% if events %}
{% for e in events %}
{{ e.glyph }} {{ e.event }} {{ e.detail or "" }} {{ e.at.strftime("%Y-%m-%d %H:%M") }}
{% endfor %}
{% else %}
No lifecycle events recorded yet. Start/stop/health changes appear here as the agent reports them over time.
{% endif %}
{% endif %} {% endblock %}