Skip to content

[docker-in-docker] - Use blocking entrypoints to ensure dockerd startup #671

@samruddhikhandale

Description

@samruddhikhandale

We have seen flakiness in docker startups for docker-in-docker Feature where docker is not running in the container. See #634 and #660.

#669 adds few retry mechanisms to attempt to fix this issue.

/usr/local/share/docker-init.sh which starts/retries dockerd is added to the entrypoint property for the Feature. This command runs in the background and is not a blocking script for the container startup. Since it's in the background, onCreateCommand/postCreateCommand/postStartCommand could all start executing before docker is fully running. If it takes docker too long, that could introduce flakiness in those lifecycle scripts.

Opened devcontainers/spec#299 which requests a new semantics to have "blocking" entrypoints that the CLI waits for. This way we can ensure that docker is already up and running for the mentioned ^ lifecycle scripts and is 💯 available in the container.

This issue tracks updates to dnd Feature, when blocking entrypoint is available.

Blocked by -

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions