Skip to content

Decision: how should the Incus switch role move onto the Traefik edge? #5484

Open

Description

@yannickmonney

Summary

The feature line (release/0.6 and feature-train) runs its edge on Traefik. The Incus runtime on main has a switch role that the feature line does not have yet: it renders the proxy's upstream files for the blue/green switch. Until that switch role is ported, managed Incus refuses any revision whose edge is Traefik. This issue records the evidence and the options for the port. It does not choose one.

What the repository says today

Anchors at main 437704e and feature-train 56fbc3c.

  • main: tools/cli/src/lib/runtime/incus/verbs/switch.ts:104. The switch role writes its upstream file with renderUpstreams(target.switch[role]).
  • main: tools/cli/src/lib/compose/services/compose-parity.test.ts:2211 and :2356. A block for "the switch role of the proxy image (Incus)", including "the switch role installs Caddyfile.switch and runs the command".
  • main: tools/cli/scripts/oci-image-metadata.test.ts:1169-1170. One build stage, "byte-identical in the six images", builds the stop-signal init from a pinned source.
  • main: tools/cli/src/lib/runtime/incus/compile/stack-target.ts:628-631. An image whose file format the CLI does not read ("nginx or Traefik") fails closed.
  • feature-train: tools/cli/src/lib/runtime/incus/compile/rules.ts:91-94. Incus refuses the labels of a Traefik revision: the routes "are read by the Traefik edge, which the Incus runtime does not run yet (feat(cli): prepare managed runtimes for the Traefik edge #5282)".
  • feature-train: tools/cli/src/lib/deployment/runtime-prepare.ts:335-338. The managed prepare path refuses a Traefik revision and names feat(cli): prepare managed runtimes for the Traefik edge #5282.

What was observed

  • On feature-train, seven parked Incus test files carry 76 skip lines (grep -c '\.skip('): incus-deploy 11, translate 11, bootstrap 16, check 18, contract 17, plan 2, names 1. The incus-deploy skips name the switch-role port as their reactivation condition (for example tools/cli/src/lib/actions/incus-deploy.test.ts:333). The skip reasons in the other six files were not all read.
  • Refusal assertions remain where they test the real compile-path refusal: the translate goldens, names, and the edge test.
  • The goldens under tools/cli/src/lib/runtime/incus/compile/__golden__/ assert the refusal today. Under the feature line's current policy they stay as they are until the port lands, then regenerate.

Not examined: whether main's upstream renderer can serve a Traefik switch as it stands; any run on a real Incus host; whether the comment at stack-target.ts:628-631, which names release/0.6, still describes the right boundary after a port.

Constraints a change must respect

  • A managed Incus host must not start a Traefik revision before the switch path is proven. The refusal is the fail-closed guard until then.
  • The six stack images keep one build stage, byte-identical. oci-image-metadata.test.ts asserts the shape.
  • The goldens change only when the port lands. Regenerate them with TALE_UPDATE_GOLDEN=1 in that change.

Options (no preference stated)

  • A. Port main's switch role as it is. Render the Traefik equivalent of the Caddyfile.switch upstream file and keep the switch command's shape. This keeps main's upstream contract.
  • B. Give Traefik its own switch mechanism. For example, one file-provider configuration per role, read by the edge. The switch verb changes shape, and the parked tests are rewritten against it.
  • C. Keep the refusal until the managed Traefik path defines the Incus equivalent. No port now; the 76 skip lines stay parked until that decision is made. The managed-path status is tracked in Decision: what is the status of #5282, and does it cover managed Incus? #5485.

Questions

  1. Should the Traefik switch keep the upstream-file contract of Caddyfile.switch, or change it?
  2. Of the 76 parked lines, which are mechanics to reactivate, and which should stay as refusal tests after the port?
  3. Can the port land on the Compose path before feat(cli): prepare managed runtimes for the Traefik edge #5282, or does it wait for it?

Related

Activity

  1. added
    needs discussion
    on Nov 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs discussion

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions