Skip to content

A single machine upgraded from v0.1.0-alpha.7 cannot get the builder #569

Backlog

Description

@samuelmbabhazi

Problem

Builds from Git (#215) run on the application's own server, in a rootless BuildKit set up by deploy/install.sh: the shipkeep-build account, the builder unit, its network rule, and the builds' filesystem (#548). A new installation of v0.1.0-alpha.8 gets all of it. So does a separate server installed earlier, through --migrate yes.

A single machine (control plane and applications together, ADR 0021) installed with v0.1.0-alpha.7 or earlier has no way to get it:

  • The control plane installer refuses an existing installation (assert_no_installation).
  • deploy/install.sh --migrate yes refuses this machine twice. Line 765: "Only a server for applications migrates", since the single machine's agent was installed with --local-control-plane and --agent-file. Line 804: the shipkeep-workloads.slice check, "This machine also hosts the control plane".

After a control plane upgrade and Upgrade agents, such a machine still deploys images. A Git application's build there fails with builder_unavailable. The message tells the user to run the installer with --migrate yes, which then refuses.

Proposal

Let an upgrade add the builder to a single machine, under the same rules as the migration:

  • check everything before the first change;
  • accept only a layout this installer wrote;
  • make the step safe to run again.

This could be --migrate yes accepting the single machine's server role, or a mode of the control plane installer. Until then, the message for builder_unavailable on a single machine should not point to a command that refuses.

Acceptance criteria

  • A single machine installed with v0.1.0-alpha.7, its control plane and agent upgraded, gets the builder and the builds' filesystem from a documented command. Its applications keep running, and a Git application then builds and deploys.
  • Running the command again changes nothing. A machine with an unexpected layout is refused before any change, with what to reconcile.
  • docs/INSTALL.md ("Upgrade") documents it, and the builder_unavailable message gives a command that works on that machine.
  • Tested on the lab's single machine: an install with the published v0.1.0-alpha.7, then the upgrade.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugpriority:P2track:cross-cutting

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions