Skip to content

build(devcontainer): move the docker-in-docker feature to 4 #5073

Closed as not planned

Description

@dan-petty

Problem or Motivation

.devcontainer/image/devcontainer.json uses the feature ghcr.io/devcontainers/features/docker-in-docker:2 (2.17.0). The newest major is 4 (4.1.3). Renovate (#4893) will offer it. Both majors change how the daemon starts in the devcontainer:

The devcontainer smoke test does not start dockerd. The owner's host is rootless Podman on WSL2, so a check on that host must show that dockerd still starts.

Research of 2026-11-12 (research-ci, record devcontainer-feature:docker-in-docker; devcontainer outdated with CLI 0.89.0).

Proposed Solution & Architectural Design

  1. Set docker-in-docker:4 in .devcontainer/image/devcontainer.json, then run devcontainer upgrade --workspace-folder . --config .devcontainer/image/devcontainer.json to write the lock.
  2. Build the devcontainer image, start it on the rootless Podman WSL2 host, start dockerd, and run a docker build and a docker run in it.
  3. If dockerd does not start, record the error and set the options that the 4.x README gives (for example iptablesSwitchAtRuntime).

Done when the image with feature 4 builds and dockerd runs a build on the owner's host.

Target Subsystem

SDLC, Git & PR Governance

Existing Tool Considered

The Dev Containers CLI (devcontainer upgrade) writes the lock. No new code.

Source: #4893

Alternatives check of 2026-11-15: in-use.
The repository already uses this tool.
Tool: devcontainers/features (https://github.com/devcontainers/features), MIT, last activity 2026-11-11, maintained.

Activity

  1. added
    source/agent
    on Nov 12, 2026
  2. added
    type/infra
    scope/devcontainer
    status/new
    value/medium
    effort/low
    on Nov 12, 2026
  3. dan-petty commented on Nov 12, 2026

    @dan-petty
    OwnerAuthor
    • Priority: P3-Low. This is a planned version upgrade with no active failure, so it is low urgency.
    • Related: feat(devcontainer): use or build Dev Container Features for the tools #4368, which asks for a different change. Both manage devcontainer features in the same config file, but #4368 converts tool installs to features while the candidate bumps one feature's major version.
  4. added
    priority/p3-low
    on Nov 12, 2026
  5. devops-cli-service commented on Nov 15, 2026

    @devops-cli-service
    Contributor

    Alternatives check: in-use

    Reason: The searches and repository facts show that the docker-in-docker feature the config already uses is published from the maintained devcontainers/features repository, whose major 4 is the upgrade the issue asks for, and the Dev Containers CLI supplies the devcontainer upgrade lock write. Together they cover the change with no new code; only the host check that dockerd starts on rootless Podman WSL2 remains project work.

    The repository already uses this tool.

    Tool: devcontainers/features (https://github.com/devcontainers/features)

    • License: MIT
    • Last activity: 2026-11-11
    • Maintained: yes

    Covers:

    • The docker-in-docker devcontainer feature that the config already uses is published from this maintained repository, so major 4 is available to bump to without new code
    • The feature's 4.x documentation gives the daemon-start options (iptablesSwitchAtRuntime, compose default) that the issue's step 3 would apply if dockerd does not start
    • The Dev Containers CLI, also open and maintained, provides devcontainer upgrade to write the lock file after the bump

    Lacks:

    • It cannot prove that dockerd starts on the owner's rootless Podman WSL2 host; the devcontainer smoke test does not start dockerd, so that build-and-run check stays a manual step on the host
    • The lock file still has to be regenerated by hand with devcontainer upgrade after the feature version changes

    Tools considered:

    Searches run:

    • devcontainer upgrade CLI lockfile devcontainer features, results: 5
    • devcontainers docker-in-docker feature version 4 iptablesSwitchAtRuntime, results: 5
    • "docker-in-docker" devcontainer feature 4.0.0 release notes, results: 5
    • github devcontainers features docker-in-docker README options, results: 5
    • devcontainers/features docker-in-docker, results: 5
    • devcontainers cli upgrade command lockfile, results: 5
    • "devcontainers/cli" github, results: 5
    • docker-in-docker devcontainer feature documentation dev container, results: 5
    • containers.dev features docker-in-docker, results: 5

    Sources:

    Checked on 2026-11-15. A person decides what this means for the item. The check changes no label and closes no issue.

  6. dan-petty commented on Nov 19, 2026

    @dan-petty
    OwnerAuthor

    Owner decision of 2026-11-19: Podman replaces Docker in the devcontainer. #6414 removes the docker-in-docker Feature and adds ghcr.io/dan-petty/devcontainer-features/podman-in-podman:1 (dan-petty/devcontainer-features#5). When #6414 merges, close this item as not planned.

  7. dan-petty commented on Nov 20, 2026

    @dan-petty
    OwnerAuthor

    Closed as not planned. #6414 (PR #6472, merged 2026-11-20) removed the docker-in-docker Feature from the devcontainer: podman-in-podman with dockerCompat replaces it, by the owner rules of 2026-11-19 (Podman replaces Docker, no Docker CLI in the devops-cli container).

  8. removed
    status/new
    on Nov 20, 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

    effort/lowpriority/p3-lowscope/devcontainersource/agenttype/infravalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions