Skip to content

Conversation

@BenderV
Copy link

@BenderV BenderV commented Jan 2, 2026

note: generated by AI, but solved my issue.

Root issue

On Debian/Ubuntu systems, the installer occasionally fails during Docker installation with a 404 Not Found error when fetching containerd.io.

This happens when:

  • apt resolves a newer containerd.io version from Docker's repository metadata
  • but the corresponding .deb file is not yet available (or temporarily missing) on the Docker CDN

In that state, repeated apt-get install containerd.io attempts always fail, even though older, valid versions are still available in the same repository.

This is a known class of issue during Docker repo syncs and CDN propagation delays.


Proposed fix

Make Docker installation resilient to missing containerd.io artifacts by adding a fallback strategy:

  1. Attempt the normal Docker install using apt (unchanged behavior in the healthy case)

  2. If it fails:

    • Refresh apt metadata
    • Enumerate all available containerd.io versions via apt-cache madison
    • Retry installation by explicitly pinning each available version (newest → oldest)
  3. Succeed as soon as a valid version is found

This ensures:

  • No behavior change when the Docker repo is consistent
  • Automatic recovery when a candidate version exists in metadata but the .deb is unavailable
  • Fully non-interactive, production-safe installs

Why this approach

  • Avoids hard-coding a specific containerd version
  • Works across Debian and Ubuntu
  • Handles transient Docker repo/CDN inconsistencies gracefully
  • Keeps the installer self-healing without user intervention

User impact

  • Fixes intermittent install failures on fresh Debian/Ubuntu systems
  • Eliminates confusing 404 Not Found errors during Docker setup
  • Improves reliability of unattended installs

When apt resolves a newer containerd.io version from Docker's repository
metadata but the .deb file is not yet available (or temporarily missing)
on the Docker CDN, the install fails with 404 errors.

This adds a fallback strategy that:
1. Attempts the normal Docker install (unchanged behavior)
2. If it fails, refreshes apt metadata and enumerates available versions
3. Retries installation by pinning each available version (newest to oldest)

This handles transient Docker repo/CDN sync issues gracefully without
hard-coding a specific containerd version.
@BenderV BenderV changed the title Fix Docker install failure when containerd.io candidate is missing from Docker repo fixt(install): Docker install failure when containerd.io candidate is missing from Docker repo Jan 2, 2026
@BenderV BenderV changed the title fixt(install): Docker install failure when containerd.io candidate is missing from Docker repo fixt(install): docker install failure when containerd.io candidate is missing from Docker repo Jan 2, 2026
@BenderV BenderV changed the title fixt(install): docker install failure when containerd.io candidate is missing from Docker repo fix(install): docker install failure when containerd.io candidate is missing from Docker repo Jan 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant