own-VPS gateway: kanidm-brand-push (community display name + logo) never reaches the public IdP (GOTCHAS #12, DIV-2) #453

Closed
opened 2026-08-11 22:48:29 +00:00 by ben · 3 comments
Owner

Divergence class

GOTCHAS #12 (VM-vs-full-install divergence) — pre-filed by the #450 audit.

(Note: this issue's original write-up was accidentally submitted as the
title field and silently truncated at the tracker's title-length limit;
the title has been corrected and the full content restored below from
docs/vm-full-install-divergence.md, DIV-2.)

The kanidm-brand-push systemd oneshot — which sets the community display
name
(kanidm system domain set-displayname) and the full-colour logo
(set-image) on the running kanidm — is emitted by the VM-mode gateway render
but by neither the full-install control-plane surface nor the front-door
render. The public IdP sign-in never wears the community name/logo on an
own-VPS full install.

See docs/vm-full-install-divergence.md Table A (kanidmDisplayNamePushBlock
row) and Open divergences DIV-2.

## Divergence class GOTCHAS #12 (VM-vs-full-install divergence) — pre-filed by the #450 audit. *(Note: this issue's original write-up was accidentally submitted as the **title** field and silently truncated at the tracker's title-length limit; the title has been corrected and the full content restored below from `docs/vm-full-install-divergence.md`, DIV-2.)* The `kanidm-brand-push` systemd oneshot — which sets the community **display name** (`kanidm system domain set-displayname`) and the full-colour **logo** (`set-image`) on the running kanidm — is emitted by the VM-mode gateway render but by **neither** the full-install control-plane surface nor the front-door render. The public IdP sign-in never wears the community name/logo on an own-VPS full install. See `docs/vm-full-install-divergence.md` Table A (`kanidmDisplayNamePushBlock` row) and Open divergences DIV-2.
ben changed title from GOTCHAS #12 (VM-vs-full-install) — pre-filed by the #450 audit The kanidm-brand-push systemd oneshot — which sets the community **display name** (kanidm system domain set-displayname) and the full-colour **logo** (set-image) on the running … to own-VPS gateway: kanidm-brand-push (community display name + logo) never reaches the public IdP (GOTCHAS #12, DIV-2) 2026-08-12 02:04:37 +00:00
Author
Owner

This was generated by AI during triage.

Triage: bug → ready-for-agent.

Redundancy check: searched the gateway render/control-plane code for the
display-name/logo push on the full-install path — not present. Confirmed by
reading the control-plane surface renderer's own doc comment, which lists the
"kanidm brand blocks" among what it deliberately omits (Ben's 2026-08-11
ruling on #443), pending its own follow-up. No prior rejection found in
.out-of-scope/. Not a UI/UX-flow change, so the design-tier gate does not
apply.

Precedent: #452 solved the identical class of problem (a VM-shaped kanidm
config block needing a front-door-shaped equivalent) by writing a new
function parallel to the VM block, rather than reusing the VM block verbatim —
targeting the public gateway's own kanidm port field instead of the VM's
loopback-bridge assumption. That's the template to follow here; the existing
VM push block cannot just be spliced in because it targets a hardcoded local
port that assumes the VM's loopback bridge, not the front-door's actual bind
port.

Agent Brief

Category: bug
Summary: The public/own-VPS gateway's kanidm sign-in never receives the
community display name or logo — the push mechanism that does this on the VM
path has no full-install-shaped counterpart.

Current behavior:
On the VM-mode gateway, a oneshot unit pushes the community display name and
logo to the running kanidm after boot, gated on a landed brand-header/logo
artifact and re-triggered on a brand re-apply. The full-install/own-VPS
gateway's control-plane surface renderer does not emit anything equivalent —
it explicitly documents this as a deliberate near-term omission, since the
VM-shaped block targets a kanidm shape (bind port, generator wiring) specific
to the VM render. The public gateway's kanidm (owned by the front-door
render) never gets the community branding pushed to it.

Desired behavior:
The full-install/own-VPS gateway's control-plane surface should emit an
equivalent brand-push unit targeting the public gateway's actual kanidm
bind port and using the same credential/generator wiring the control-plane
surface already declares (the admin credential from the kanidm-admins
generator). Gating semantics (no header → no unit; brand re-apply →
re-trigger; logo optional) should match the VM behavior. It should only be
emitted when the gateway facts carry a public-gateway shape, mirroring how
the #452 provisioning fix scoped itself.

Key interfaces:

  • The gateway control-plane surface renderer — needs a new block/function
    parallel to the existing VM-mode display-name-push renderer, following the
    same shape #452's kanidm-provision fix used (a new function emitted only
    for the public-gateway shape, reading that shape's own kanidm port instead
    of the VM's hardcoded loopback assumption)
  • The community-header and landed-logo path constants the VM block already
    reads (unchanged — reuse them)
  • GatewayFacts — the public-gateway kanidm port field the front-door render
    already uses to bind kanidm; the new block must target that port, not the
    VM's hardcoded one

Acceptance criteria:

  • A full-install/own-VPS gateway with a landed community-brand header
    gets a systemd oneshot that pushes the display name to the running
    kanidm at its actual bind address/port
  • When a logo is also landed, the same unit (or a paired one) pushes the
    logo via set-image
  • No brand header landed → no unit emitted (mkIf-equivalent honest no-op,
    no broken eval)
  • A brand re-apply (header/logo bytes change) re-triggers the push, same
    restart-trigger mechanism as the VM path
  • Unit tests cover: block presence in the full-install control-plane
    surface output, and that it targets the public gateway's kanidm port
    rather than a hardcoded VM-shaped one
  • docs/vm-full-install-divergence.md's DIV-2 row is updated to CLOSED
    with the closing issue, in the same commit (ADR 0042 same-commit law)

Out of scope:

  • Changing the VM-mode push block itself
  • Any front-door/Caddy routing changes
  • The logo-bytes landing mechanism itself (already closed by DDR 0147)
> *This was generated by AI during triage.* **Triage: bug → ready-for-agent.** Redundancy check: searched the gateway render/control-plane code for the display-name/logo push on the full-install path — not present. Confirmed by reading the control-plane surface renderer's own doc comment, which lists the "kanidm brand blocks" among what it *deliberately* omits (Ben's 2026-08-11 ruling on #443), pending its own follow-up. No prior rejection found in `.out-of-scope/`. Not a UI/UX-flow change, so the design-tier gate does not apply. Precedent: #452 solved the identical class of problem (a VM-shaped kanidm config block needing a front-door-shaped equivalent) by writing a **new** function parallel to the VM block, rather than reusing the VM block verbatim — targeting the public gateway's own kanidm port field instead of the VM's loopback-bridge assumption. That's the template to follow here; the existing VM push block cannot just be spliced in because it targets a hardcoded local port that assumes the VM's loopback bridge, not the front-door's actual bind port. ## Agent Brief **Category:** bug **Summary:** The public/own-VPS gateway's kanidm sign-in never receives the community display name or logo — the push mechanism that does this on the VM path has no full-install-shaped counterpart. **Current behavior:** On the VM-mode gateway, a oneshot unit pushes the community display name and logo to the running kanidm after boot, gated on a landed brand-header/logo artifact and re-triggered on a brand re-apply. The full-install/own-VPS gateway's control-plane surface renderer does not emit anything equivalent — it explicitly documents this as a deliberate near-term omission, since the VM-shaped block targets a kanidm shape (bind port, generator wiring) specific to the VM render. The public gateway's kanidm (owned by the front-door render) never gets the community branding pushed to it. **Desired behavior:** The full-install/own-VPS gateway's control-plane surface should emit an equivalent brand-push unit targeting the *public* gateway's actual kanidm bind port and using the same credential/generator wiring the control-plane surface already declares (the admin credential from the kanidm-admins generator). Gating semantics (no header → no unit; brand re-apply → re-trigger; logo optional) should match the VM behavior. It should only be emitted when the gateway facts carry a public-gateway shape, mirroring how the #452 provisioning fix scoped itself. **Key interfaces:** - The gateway control-plane surface renderer — needs a new block/function parallel to the existing VM-mode display-name-push renderer, following the same shape #452's kanidm-provision fix used (a new function emitted only for the public-gateway shape, reading that shape's own kanidm port instead of the VM's hardcoded loopback assumption) - The community-header and landed-logo path constants the VM block already reads (unchanged — reuse them) - `GatewayFacts` — the public-gateway kanidm port field the front-door render already uses to bind kanidm; the new block must target that port, not the VM's hardcoded one **Acceptance criteria:** - [ ] A full-install/own-VPS gateway with a landed community-brand header gets a systemd oneshot that pushes the display name to the running kanidm at its *actual* bind address/port - [ ] When a logo is also landed, the same unit (or a paired one) pushes the logo via `set-image` - [ ] No brand header landed → no unit emitted (mkIf-equivalent honest no-op, no broken eval) - [ ] A brand re-apply (header/logo bytes change) re-triggers the push, same restart-trigger mechanism as the VM path - [ ] Unit tests cover: block presence in the full-install control-plane surface output, and that it targets the public gateway's kanidm port rather than a hardcoded VM-shaped one - [ ] `docs/vm-full-install-divergence.md`'s DIV-2 row is updated to CLOSED with the closing issue, in the same commit (ADR 0042 same-commit law) **Out of scope:** - Changing the VM-mode push block itself - Any front-door/Caddy routing changes - The logo-bytes landing mechanism itself (already closed by DDR 0147)
Author
Owner

swarm-claim host=matou-dev-server-01 run=4920
(automated multi-host claim — lowest live claim id works this ticket)

swarm-claim host=matou-dev-server-01 run=4920 (automated multi-host claim — lowest live claim id works this ticket)
Author
Owner

close-report for #453 — status success

✅ close-report gates passed — every claim verified against main; closing.

envelope
{
  "issue": 453,
  "status": "success",
  "commits": [
    "bc2123180bf5cfc1044caaf75d8a593cc326e959"
  ],
  "changed_files": [
    "internal/clan/vmguest.go",
    "internal/clan/vmguest_test.go",
    "docs/vm-full-install-divergence.md",
    "STATUS.md"
  ],
  "tests": [
    {
      "command": "nix develop .#go-ci -c go test ./internal/clan/",
      "exit_code": 0
    },
    {
      "command": "nix develop .#go-ci -c go test ./internal/clan/ -run 'BrandPush|NilPublic'",
      "exit_code": 0
    },
    {
      "command": "nix-instantiate --parse /tmp/control-plane.nix",
      "exit_code": 0
    }
  ],
  "criteria": {
    "A full-install/own-VPS gateway with a landed community-brand header gets a systemd oneshot that pushes the display name to the running kanidm at its actual bind address/port": "gatewayBrandPush (internal/clan/vmguest.go) emits systemd.services.kanidm-brand-push with KANIDM_URL=https://127.0.0.1:<Public.KanidmPort> and `kanidm system domain set-displayname`; composed into renderControlPlaneSurface. Asserted by TestRenderControlPlaneSurface_EmitsBrandPush (targets :8449).",
    "When a logo is also landed, the same unit pushes the logo via set-image": "The block's `lib.optionalString haveLogo` half runs `kanidm system domain set-image --name admin ${brandLogo} \"$(cat ${brandLogoType})\"`, guarded on builtins.pathExists of BrandLogoPath + its type sidecar. Asserted in the same test.",
    "No brand header landed -> no unit emitted (mkIf-equivalent honest no-op, no broken eval)": "The unit is `lib.mkIf (builtins.pathExists brandHeader) { ... }`; rendered module nix-instantiate --parse clean. Asserted by the mkIf fragment in TestRenderControlPlaneSurface_EmitsBrandPush.",
    "A brand re-apply (header/logo bytes change) re-triggers the push, same restart-trigger mechanism as the VM path": "restartTriggers = [ brandHeader ] ++ lib.optionals haveLogo [ brandLogo brandLogoType ]; — the header/logo are Nix path literals, so a re-apply's new store hash re-runs the oneshot. Asserted by the restartTriggers fragment in the test.",
    "Unit tests cover block presence in the full-install control-plane surface output, and that it targets the public gateway's kanidm port rather than a hardcoded VM-shaped one": "TestRenderControlPlaneSurface_EmitsBrandPush asserts the block present and KANIDM_URL=https://127.0.0.1:8449 present AND https://localhost:8443 absent; TestRenderControlPlaneSurface_NilPublicOmitsBrandPush covers the nil-Public honest no-op.",
    "docs/vm-full-install-divergence.md's DIV-2 row is updated to CLOSED with the closing issue, in the same commit (ADR 0042 same-commit law)": "Same commit bc21231: DIV-2 Open-divergences row and Table A kanidmDisplayNamePushBlock row both updated to CLOSED #453."
  },
  "summary": "The own-VPS/full-install control-plane surface now emits a kanidm-brand-push oneshot (gatewayBrandPush) pushing the community display name + logo to the front-door kanidm at its actual 127.0.0.1:<Public.KanidmPort> bind, closing DIV-2.",
  "reason": "",
  "blockers": []
}
**close-report** for #453 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; closing. <details><summary>envelope</summary> ```json { "issue": 453, "status": "success", "commits": [ "bc2123180bf5cfc1044caaf75d8a593cc326e959" ], "changed_files": [ "internal/clan/vmguest.go", "internal/clan/vmguest_test.go", "docs/vm-full-install-divergence.md", "STATUS.md" ], "tests": [ { "command": "nix develop .#go-ci -c go test ./internal/clan/", "exit_code": 0 }, { "command": "nix develop .#go-ci -c go test ./internal/clan/ -run 'BrandPush|NilPublic'", "exit_code": 0 }, { "command": "nix-instantiate --parse /tmp/control-plane.nix", "exit_code": 0 } ], "criteria": { "A full-install/own-VPS gateway with a landed community-brand header gets a systemd oneshot that pushes the display name to the running kanidm at its actual bind address/port": "gatewayBrandPush (internal/clan/vmguest.go) emits systemd.services.kanidm-brand-push with KANIDM_URL=https://127.0.0.1:<Public.KanidmPort> and `kanidm system domain set-displayname`; composed into renderControlPlaneSurface. Asserted by TestRenderControlPlaneSurface_EmitsBrandPush (targets :8449).", "When a logo is also landed, the same unit pushes the logo via set-image": "The block's `lib.optionalString haveLogo` half runs `kanidm system domain set-image --name admin ${brandLogo} \"$(cat ${brandLogoType})\"`, guarded on builtins.pathExists of BrandLogoPath + its type sidecar. Asserted in the same test.", "No brand header landed -> no unit emitted (mkIf-equivalent honest no-op, no broken eval)": "The unit is `lib.mkIf (builtins.pathExists brandHeader) { ... }`; rendered module nix-instantiate --parse clean. Asserted by the mkIf fragment in TestRenderControlPlaneSurface_EmitsBrandPush.", "A brand re-apply (header/logo bytes change) re-triggers the push, same restart-trigger mechanism as the VM path": "restartTriggers = [ brandHeader ] ++ lib.optionals haveLogo [ brandLogo brandLogoType ]; — the header/logo are Nix path literals, so a re-apply's new store hash re-runs the oneshot. Asserted by the restartTriggers fragment in the test.", "Unit tests cover block presence in the full-install control-plane surface output, and that it targets the public gateway's kanidm port rather than a hardcoded VM-shaped one": "TestRenderControlPlaneSurface_EmitsBrandPush asserts the block present and KANIDM_URL=https://127.0.0.1:8449 present AND https://localhost:8443 absent; TestRenderControlPlaneSurface_NilPublicOmitsBrandPush covers the nil-Public honest no-op.", "docs/vm-full-install-divergence.md's DIV-2 row is updated to CLOSED with the closing issue, in the same commit (ADR 0042 same-commit law)": "Same commit bc21231: DIV-2 Open-divergences row and Table A kanidmDisplayNamePushBlock row both updated to CLOSED #453." }, "summary": "The own-VPS/full-install control-plane surface now emits a kanidm-brand-push oneshot (gatewayBrandPush) pushing the community display name + logo to the front-door kanidm at its actual 127.0.0.1:<Public.KanidmPort> bind, closing DIV-2.", "reason": "", "blockers": [] } ``` </details>
ben closed this issue 2026-08-12 03:29:44 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Matou/idss#453
No description provided.