From 98f5af3eef320905e1958083abd21618648e851d Mon Sep 17 00:00:00 2001 From: Sam Catlow Date: Mon, 9 Nov 2026 02:03:20 +1100 Subject: [PATCH] refactor(ui): merge the harness settings page into agent profiles The harness page's setup terminal targets the Kit agent profiles, so the two pages were two halves of one flow split across routes: with no Kit profile the harness page dead-ended in a disabled 'No profiles configured' select while the place to create one sat on another page. /settings/agent-profiles now carries the profiles editor and a 'Harness sign-in' section (setup terminal plus the credential-bindings sign-in table), and /settings/harness redirects to it. The bindings re-read when a terminal session ends so a fresh capture shows immediately, and a null-seeded agent-profiles document now renders the empty state instead of a bare add form. The gateway page registry names the merged page. --- internal/gateway/dashboard_tools.go | 2 +- ui/src/harness/HarnessPage.vue | 188 -------------------------- ui/src/lib/nav.ts | 1 - ui/src/router/index.ts | 16 +-- ui/src/settings/AgentProfilesPage.vue | 171 ++++++++++++++++++++++- 5 files changed, 170 insertions(+), 208 deletions(-) delete mode 100644 ui/src/harness/HarnessPage.vue diff --git a/internal/gateway/dashboard_tools.go b/internal/gateway/dashboard_tools.go index 7fc23dba1..584c8a920 100644 --- a/internal/gateway/dashboard_tools.go +++ b/internal/gateway/dashboard_tools.go @@ -56,7 +56,7 @@ var dashboardPages = []DashboardPage{ {Path: "/settings/plugins", Label: "Plugins", Description: "Extension directories loaded at startup."}, {Path: "/settings/secret-engines", Label: "Secret engines"}, {Path: "/settings/container-runtime", Label: "Container runtime"}, - {Path: "/settings/harness", Label: "Harness", Description: "OAuth credential bindings and setup terminal."}, + {Path: "/settings/agent-profiles", Label: "Agent profiles", Description: "Execution profiles (image or Kit harness), credential sign-in status and the harness setup terminal."}, } // DashboardPages returns a copy of the dashboard page registry. diff --git a/ui/src/harness/HarnessPage.vue b/ui/src/harness/HarnessPage.vue deleted file mode 100644 index a3d9ff010..000000000 --- a/ui/src/harness/HarnessPage.vue +++ /dev/null @@ -1,188 +0,0 @@ - - - diff --git a/ui/src/lib/nav.ts b/ui/src/lib/nav.ts index e7c1125d0..9b3a2141b 100644 --- a/ui/src/lib/nav.ts +++ b/ui/src/lib/nav.ts @@ -77,7 +77,6 @@ const settings: NavSpec = { "/settings/task-execution", "/settings/container-runtime", "/settings/agent-profiles", - "/settings/harness", "/settings/status", ], }, diff --git a/ui/src/router/index.ts b/ui/src/router/index.ts index fcb6461b7..be27faabb 100644 --- a/ui/src/router/index.ts +++ b/ui/src/router/index.ts @@ -395,19 +395,9 @@ const routes = [ component: () => import("@/settings/AgentProfilesPage.vue"), meta: { navPath: "/settings", settings: true, label: "Agent profiles", section: "settings" }, }, - { - path: "/settings/harness", - name: "settings-harness", - // Lazy so xterm.js stays out of the shell every page loads. - component: () => import("@/harness/HarnessPage.vue"), - meta: { - navPath: "/settings", - settings: true, - label: "Harness", - description: "OAuth credential bindings and setup terminal.", - section: "settings", - }, - }, + // The harness sign-in section lives on the agent-profiles page: its setup + // terminal targets the Kit profiles that page edits. + { path: "/settings/harness", redirect: "/settings/agent-profiles", meta: { nav: false } }, { path: "/settings/history", redirect: (to: RouteLocationGeneric) => ({ path: "/org/audit", query: to.query, hash: to.hash }), meta: { nav: false } }, { path: "/settings/audit", redirect: (to: RouteLocationGeneric) => ({ path: "/org/audit", query: to.query, hash: to.hash }), meta: { nav: false } }, { diff --git a/ui/src/settings/AgentProfilesPage.vue b/ui/src/settings/AgentProfilesPage.vue index 80cc40c6b..53c2b5c34 100644 --- a/ui/src/settings/AgentProfilesPage.vue +++ b/ui/src/settings/AgentProfilesPage.vue @@ -1,13 +1,25 @@