Skip to content

Ryuk container in Docker-Toolbox on Windows 7 #599

@trevorpgray

Description

@trevorpgray

I ran into an issue on Windows 7 using testcontainers 1.6.0

The issue presented the same as #84, specifically issue-84-comment

So the error comes when testcontainers makes the startup checks and tries to mount C:\Users\user\AppData\Local\Temp.testcontainers-tmp-6153256460751889885:/dummy:ro
Error from docker daemon is:

{"message":"invalid volume specification: 'C:\Users\user\AppData\Local\Temp\.testcontainers-tmp-6153256460751889885:/dummy:ro'"}

Disabling checks was the proposed workaround, however t seems like the problem is that the ryuk container attempts to mount the volume regardless of whether or not the checks are run:

// Not needed for Ryuk, but we perform pre-flight checks with it (micro optimization)
new Bind(mountableFile.getResolvedPath(), new Volume("/dummy"), AccessMode.ro)

String ryukContainerId = ResourceReaper.start(hostIpAddress, client);
log.info("Ryuk started - will monitor and terminate Testcontainers containers on JVM exit");
VisibleAssertions.info("Checking the system...");
checkDockerVersion(version.getVersion());
if (!TestcontainersConfiguration.getInstance().isDisableChecks()) {
checkDiskSpace(client, ryukContainerId);
checkMountableFile(client, ryukContainerId);
}

The workaround is to downgrade to version 1.5.1 (before the ryuk container) and disable the checks.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions