summaryrefslogtreecommitdiff
path: root/src/marlin.web/Views/Agents/Details.cshtml
diff options
context:
space:
mode:
Diffstat (limited to 'src/marlin.web/Views/Agents/Details.cshtml')
-rw-r--r--src/marlin.web/Views/Agents/Details.cshtml67
1 files changed, 67 insertions, 0 deletions
diff --git a/src/marlin.web/Views/Agents/Details.cshtml b/src/marlin.web/Views/Agents/Details.cshtml
new file mode 100644
index 0000000..3512a98
--- /dev/null
+++ b/src/marlin.web/Views/Agents/Details.cshtml
@@ -0,0 +1,67 @@
+@using marlin.core.models
+@model Agent
+
+<div class="row">
+ <div class="col">
+ <h3>Details</h3>
+ <hr/>
+ <form method="post" asp-route-id="@Model.Id" asp-action="Edit">
+ <dl>
+ <dt>Name</dt>
+ <dd>
+ <input type="text" name="@nameof(Agent.Name)" value="@Model.Name"/>
+ </dd>
+
+ <dt>Max Concurrent Jobs</dt>
+ <dd>
+ <input type="number" name="@nameof(Agent.MaxConcurrentJobs)" value="@Model.MaxConcurrentJobs"/>
+ </dd>
+
+ <dt>Last Seen</dt>
+ <dd>
+ @Model.LastSeen.ToString("G")
+ </dd>
+
+ <button type="submit">Save</button>
+ </dl>
+ </form>
+ </div>
+
+ <div class="col">
+ <h3>Setup</h3>
+ <hr/>
+ <form method="post" asp-route-id="@Model.Id" asp-action="RegenerateToken">
+ <dl>
+ <dt>Agent ID</dt>
+ <dd>
+ @Model.Id
+ </dd>
+
+ <dt>Auth Token</dt>
+ <dd>
+ @Model.AuthToken
+ </dd>
+
+ <button type="submit">Regenerate</button>
+ </dl>
+ </form>
+ </div>
+</div>
+
+<h3>Capabilities</h3>
+<hr/>
+<table class="vertable">
+ <tbody>
+ @foreach (var capability in Model.Capabilities.Items)
+ {
+ <tr>
+ <td>@capability.Key</td>
+ <td>@capability.Value</td>
+ </tr>
+ }
+ </tbody>
+</table>
+
+<a asp-controller="Jobs" asp-action="List" asp-route-Agent="@Model.Id" asp-route-Status="@JobStatus.Active">Active
+ jobs</a>
+<a asp-action="List">Back</a>