36 lines
1.4 KiB
HTML
36 lines
1.4 KiB
HTML
{% extends "base.html" %}
|
|
|
|
{% block title %}Job #{{ job.id }} | left4me{% endblock %}
|
|
|
|
{% block content %}
|
|
<section class="panel">
|
|
<div class="page-heading">
|
|
<h1>Job #{{ job.id }}</h1>
|
|
{% if job.state in ["queued", "running"] %}
|
|
<form method="post" action="/jobs/{{ job.id }}/cancel" class="inline-form">
|
|
<input type="hidden" name="csrf_token" value="{{ session.get('csrf_token', '') }}">
|
|
<input type="hidden" name="next" value="/jobs/{{ job.id }}">
|
|
<button class="danger" type="submit">cancel</button>
|
|
</form>
|
|
{% endif %}
|
|
</div>
|
|
|
|
<table class="definition-table">
|
|
<tbody>
|
|
<tr><th>Operation</th><td>{{ job.operation }}</td></tr>
|
|
<tr><th>State</th><td>{{ job.state }}</td></tr>
|
|
<tr><th>User</th><td>{{ owner.username }}</td></tr>
|
|
<tr><th>Server</th><td>{% if server %}<a href="/servers/{{ server.id }}">{{ server.name }}</a>{% else %}-{% endif %}</td></tr>
|
|
<tr><th>Created</th><td>{{ job.created_at }}</td></tr>
|
|
<tr><th>Started</th><td>{{ job.started_at or "-" }}</td></tr>
|
|
<tr><th>Finished</th><td>{{ job.finished_at or "-" }}</td></tr>
|
|
<tr><th>Exit code</th><td>{{ job.exit_code if job.exit_code is not none else "-" }}</td></tr>
|
|
</tbody>
|
|
</table>
|
|
</section>
|
|
|
|
<section class="panel">
|
|
<h2>Job Logs</h2>
|
|
<pre class="log-stream" data-sse-url="/jobs/{{ job.id }}/stream"></pre>
|
|
</section>
|
|
{% endblock %}
|