Separate campaigns from server deployment lifecycle tracking

This commit is contained in:
2026-09-17 16:42:37 -04:00
parent 6c6e63fa80
commit 6f83700161
20 changed files with 1434 additions and 1108 deletions
+5 -5
View File
@@ -98,7 +98,7 @@
async function loadServer(): Promise<void> {
const [srvRes, depRes, invRes] = await Promise.all([
fetch('/api/servers'),
fetch('/api/deployments'),
fetch('/api/campaigns'),
fetch(`/api/servers/${encodeURIComponent(name)}/scripts`)
]);
const srvBody = (await srvRes.json()) as { servers: Server[]; integrations: Integrations };
@@ -211,7 +211,7 @@
if (destroying || !name) return;
const confirmed = confirm(
`Destroy ${name}?\n\nThis stops the container, deletes the Komodo deployment, ` +
`removes the host directory, and drops all deployment history for this server. Cannot be undone.`
`removes the host directory, and removes this server?s campaign details. Server deployment history is retained. Cannot be undone.`
);
if (!confirmed) return;
destroying = true; destroyError = null; destroyWarnings = [];
@@ -520,19 +520,19 @@
{:else if activeTab === 'history'}
<Card padding="lg">
<div class="panel-head">
<h2>Deployment history</h2>
<h2>Campaign history</h2>
<span class="panel-count">{history.length}</span>
</div>
{#if history.length === 0}
<EmptyState
title="No deployments yet"
title="No campaigns yet"
description="Nothing has been pushed to this server. Open a beta or push scripts to see history here."
/>
{:else}
<div class="history">
{#each history as d (d.id)}
{@const mine = d.servers.find((s) => s.server === name)!}
<a class="hist-row s-{mine.restart_state}" href="/deployments/{d.id}">
<a class="hist-row s-{mine.restart_state}" href="/campaigns/{d.id}">
<span class="hist-action">{d.action}</span>
<span class="hist-state">
<Badge