- #5298 "Docker overview: verdict line; only the problem tiles that aren't zero" - #5299 "Docker overview: swarm services as a filterable, sortable table with a Stack column" - #5300 "Docker overview: failures listed once, each with a link to the failed task's logs" - #5301 "Docker overview: standalone containers in one table with a Host column" - #5302 "Service page: replicas, image, task history, resource history and logs across all its tasks" overview.py holds the rows, filters and sort as plain functions. The filter bar sits outside the polled fragment and the URL keeps its state. A service's page reads every task container Steward still holds anything for, the live ones and removed ones known by their events, so a failed task's logs are reachable after Docker has removed it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
25 lines
1.4 KiB
HTML
25 lines
1.4 KiB
HTML
{# docker/_container_logs_lines.html — log-line fragment, HTMX-polled (m79).
|
|
{{ l.line }} is auto-escaped by Jinja, so log content can't inject markup.
|
|
A service's lines (#5302) carry the task each came from. #}
|
|
{% if lines %}
|
|
{% for l in lines %}
|
|
<div style="display:flex;gap:0.6rem;white-space:pre-wrap;word-break:break-word;">
|
|
<span style="color:var(--text-dim);flex-shrink:0;" title="{{ l.ts }}">{{ l.ts.strftime("%m-%d %H:%M:%S") }}</span>
|
|
{% if l.task %}<span class="tone-muted" style="flex-shrink:0;white-space:nowrap;" title="Slot and task id">{{ l.task }}</span>{% endif %}
|
|
<span style="flex-shrink:0;width:3.2rem;color:{% if l.stream == 'stderr' %}var(--red){% else %}var(--text-muted){% endif %};">{{ l.stream }}</span>
|
|
<span style="flex:1;min-width:0;{% if l.stream == 'stderr' %}color:var(--text);{% endif %}">{{ l.line }}</span>
|
|
</div>
|
|
{% endfor %}
|
|
{% else %}
|
|
<div style="color:var(--text-muted);padding:1rem 0.25rem;">
|
|
{% if filtered %}
|
|
No lines match the current filter.
|
|
{% else %}
|
|
No logs collected yet for <code>{{ name }}</code>. Lines appear within a few
|
|
seconds of {{ "one of its tasks" if service else "the container" }} writing to stdout/stderr — unless it's on the log
|
|
exclude list or log collection is turned off in
|
|
<a href="/settings/thresholds/">Settings → Thresholds & Retention</a>.
|
|
{% endif %}
|
|
</div>
|
|
{% endif %}
|