Working now
{% for job in running %}
{% call m.row(job.name, job.state,
[("step", job.current_step), ("progress", job.progress ~ "/" ~ job.total_steps),
("started", job.started)], "/activity", "row-" ~ job.id,
none, job.status) %}
{{ m.follow_button("Logs", job.name, job.log_url) }}
{% endcall %}
{% endfor %}
{% endif %}
{#
The machine's vital signs over time. The history comes from
/api/metrics/{metric} and the live edge rides the metrics event on the
shared /events stream; panel.js owns both, keyed off the data-chart hooks.
The buttons are read by the client rather than being links: switching the
window re-reads history without a navigation, and a plain data attribute is
all the delegated click listener needs under script-src 'self'.
#}
Applications
{% if apps %}
{% for app in apps %}
{% call m.row(app.domain, app.state, app.meta, app.href, "row-" ~ app.id,
none, app.state_text) %}
{{ m.follow_button("Logs", app.domain, app.log_url) }}
{{ m.action_button("Restart", app.restart_endpoint, none, "Restarted " ~ app.domain) }}
{% endcall %}
{% endfor %}
{% else %}
{{ m.empty(
"No applications yet",
"Deploy one from a Git repository, an archive or a local directory.",
command="wasm create -d example.com -s https://github.com/you/app") }}
{% endif %}