Skip to content

Installer: a failed Docker download blocks the next run until two files are removed by hand #327

Closed

Description

@samuelmbabhazi

What happens

On a slow or unstable connection, the control plane installer can fail while apt downloads the Docker packages:

E: Failed to fetch https://download.docker.com/.../containerd.io_...deb  Connection timed out
E: Failed to fetch https://download.docker.com/.../docker-ce_...deb  Temporary failure resolving 'download.docker.com'
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

The installer stops, which is right. But the next run refuses to start:

shipkeep-install: An earlier run left /etc/apt/sources.list.d/shipkeep-docker.sources or
/etc/apt/keyrings/shipkeep-docker.gpg: remove both, then run this installer again.

The operator has to remove two files by hand before the same command works again. After that the installation completes normally.

Seen on 2026-11-17 with the published v0.1.0-alpha.2 bundle on a fresh Ubuntu 24.04, twice in a row on a connection that dropped DNS answers for a few seconds.

Why it matters

A failed download is the most ordinary failure an installer meets, and it is not the operator's fault. The message is clear, but the installer wrote those two files itself and could deal with them.

The server installer (deploy/install.sh) has the same check, with a shorter message (Docker repository files already exist.), and a third file (shipkeep-docker.asc).

Possible fix

Either of these, in both installers:

  • remove the repository file and the key when the Docker installation fails (a trap limited to that function), so that a failed run leaves nothing behind; or
  • accept the files on the next run when they are exactly what the installer writes: the same .sources content and a key ring holding only the pinned fingerprint. Anything else is still refused.

The second keeps the current guarantee (apt only ever trusts the pinned key) and also covers a run interrupted with Ctrl-C.

Acceptance

  • After a failed package download, running the installer again works without removing anything by hand.
  • A repository file or key ring that the installer did not write is still refused.
  • deploy/control-plane/install_test.sh covers both cases, and the same for the server installer.

Activity

  1. added
    bug
    on Nov 17, 2026
  2. iyuzhang commented on Nov 18, 2026

    @iyuzhang
    Contributor

    I’ll take this and test retrying both installers after an interrupted package download.

  3. samuelmbabhazi commented on Nov 18, 2026

    @samuelmbabhazi
    CollaboratorAuthor

    Good to see you back @iyuzhang, and thanks for picking this one up after #320. It's yours.

    Two things you can't see from the issue alone:

    • deploy/control-plane/install.sh and its tests changed a lot today with feat(deploy): the installer creates the first account, email becomes optional #332, so please start from the latest main.
    • Of the two fixes listed, the second fits best: on the next run, accept the files only when they are exactly what the installer writes (same .sources, a keyring holding only the pinned key), and refuse anything else. It keeps apt trusting the pinned key alone, and also covers a run stopped with Ctrl-C.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions