Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

Keep setup completion identity local

rcourtman0849c316db87
diff --git a/docs/release-control/v6/internal/subsystems/agent-lifecycle.md b/docs/release-control/v6/internal/subsystems/agent-lifecycle.md
index 633ff7a3a3..5a509cfdd5 100644
--- a/docs/release-control/v6/internal/subsystems/agent-lifecycle.md
+++ b/docs/release-control/v6/internal/subsystems/agent-lifecycle.md
@@ -970,6 +970,11 @@ inventory. It may not present Docker, Kubernetes, Proxmox, or TrueNAS as
competing primary onboarding paths, nor fall back to logo-led feature
brochure copy that obscures the unified-resource contract the wizard is
supposed to introduce.
+That same connected-systems summary must preserve canonical local operator
+identity for newly connected infrastructure. When governed resources such as
+PBS or PMG appear in the setup-completion poll, the surface must show their
+local instance labels instead of replacing those identities with governed
+summary text, so the operator can tell which system actually connected.
That same first-session setup-completion surface must also honor the lane's
optional-auth install contract: when Pulse does not require API tokens, the
wizard may switch to tokenless install commands only after an explicit operator
diff --git a/frontend-modern/src/components/SetupWizard/SetupCompletionPanel.tsx b/frontend-modern/src/components/SetupWizard/SetupCompletionPanel.tsx
index cc4ab82a99..e69c87f2f4 100644
--- a/frontend-modern/src/components/SetupWizard/SetupCompletionPanel.tsx
+++ b/frontend-modern/src/components/SetupWizard/SetupCompletionPanel.tsx
@@ -18,7 +18,7 @@ import {
trackUpgradeClicked,
} from '@/utils/upgradeMetrics';
import {
- getPreferredResourceDisplayName,
+ getPreferredInfrastructureDisplayName,
getPreferredResourceHostname,
} from '@/utils/resourceIdentity';
import {
@@ -90,7 +90,7 @@ const hasAgentFacet = (resource: Resource): boolean => resourceHasAgentFacet(res
const toNodeSummaryShape = (resource: Resource) => {
const platformData = pd(resource);
const proxmox = asRecord(platformData?.proxmox);
- const name = getPreferredResourceDisplayName(resource);
+ const name = getPreferredInfrastructureDisplayName(resource);
return {
id: resource.id,
name,
@@ -101,7 +101,7 @@ const toNodeSummaryShape = (resource: Resource) => {
const toAgentSummaryShape = (resource: Resource) => {
const hostname = getPreferredResourceHostname(resource) || resource.id;
- const name = getPreferredResourceDisplayName(resource);
+ const name = getPreferredInfrastructureDisplayName(resource);
const id = getActionableAgentIdFromResource(resource) || resource.id;
return {
id,
diff --git a/frontend-modern/src/components/SetupWizard/__tests__/SetupCompletionPanel.guardrails.test.ts b/frontend-modern/src/components/SetupWizard/__tests__/SetupCompletionPanel.guardrails.test.ts
index 0d8edfd198..d0cda16596 100644
--- a/frontend-modern/src/components/SetupWizard/__tests__/SetupCompletionPanel.guardrails.test.ts
+++ b/frontend-modern/src/components/SetupWizard/__tests__/SetupCompletionPanel.guardrails.test.ts
@@ -29,6 +29,11 @@ describe('SetupCompletionPanel guardrails', () => {
expect(setupCompletionPanelSource).not.toContain('ProxmoxIcon');
});
+ it('keeps connected infrastructure labels on the canonical local identity helper', () => {
+ expect(setupCompletionPanelSource).toContain('getPreferredInfrastructureDisplayName');
+ expect(setupCompletionPanelSource).not.toContain('getPreferredResourceDisplayName(resource)');
+ });
+
it('does not reintroduce a separate setup-wizard install command surface', () => {
expect(setupCompletionPanelSource).not.toContain('buildUnixAgentInstallCommand');
expect(setupCompletionPanelSource).not.toContain('buildWindowsAgentInstallCommand');
diff --git a/frontend-modern/src/components/SetupWizard/__tests__/SetupCompletionPanel.test.tsx b/frontend-modern/src/components/SetupWizard/__tests__/SetupCompletionPanel.test.tsx
index 5825569968..f5b8e9e1bf 100644
--- a/frontend-modern/src/components/SetupWizard/__tests__/SetupCompletionPanel.test.tsx
+++ b/frontend-modern/src/components/SetupWizard/__tests__/SetupCompletionPanel.test.tsx
@@ -192,6 +192,41 @@ describe('SetupCompletionPanel', () => {
expect(onComplete).toHaveBeenCalledWith('/');
});
+ it('keeps connected governed infrastructure on local operator identity', async () => {
+ apiFetchJSONMock.mockResolvedValue({
+ resources: [
+ {
+ id: 'pbs-1',
+ type: 'pbs',
+ name: 'redacted-pbs',
+ displayName: 'PBS Main',
+ status: 'online',
+ agent: { agentId: 'pbs-1' },
+ platformData: {
+ pbs: { hostname: 'pbs.local', instanceId: 'pbs-main' },
+ },
+ policy: {
+ display: {
+ mode: 'governed',
+ summary: 'backup server resource; status online; sources pbs',
+ },
+ },
+ },
+ ],
+ });
+
+ render(() => <SetupCompletionPanel state={baseState} onComplete={vi.fn()} />);
+
+ await waitFor(() => {
+ expect(screen.getByText('Connected (1 agent)')).toBeInTheDocument();
+ });
+
+ expect(screen.getByText('PBS Main')).toBeInTheDocument();
+ expect(
+ screen.queryByText('backup server resource; status online; sources pbs'),
+ ).not.toBeInTheDocument();
+ });
+
it('routes relay setup through the canonical settings destination', async () => {
const onComplete = vi.fn();
apiFetchJSONMock.mockResolvedValue({