question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

windows volume mount exception

See original GitHub issue

I am not sure if this is a bug or something I am doing wrong, but here it goes:

I create a container using:

  • .withWorkingDir(WORKSPACE), where workspace is fort example /workspace
  • .withBinds(Bind.parse(volumePath + “:” + WORKSPACE)) , where volumePath is D:\testpath

When trying to create the container, the following exception is run:

Caught: com.github.dockerjava.api.exception.InternalServerErrorException: invalid volume specification: '/host_mnt/d/testpath:rw'
com.github.dockerjava.api.exception.InternalServerErrorException: invalid volume specification: '/host_mnt/d/testpath:rw'
 at com.github.dockerjava.jaxrs.filter.ResponseStatusExceptionFilter.filter(ResponseStatusExceptionFilter.java:72)
 at org.glassfish.jersey.client.ClientFilteringStages$ResponseFilterStage.apply(ClientFilteringStages.java:171)
 at org.glassfish.jersey.client.ClientFilteringStages$ResponseFilterStage.apply(ClientFilteringStages.java:159)
 at org.glassfish.jersey.process.internal.Stages.process(Stages.java:147)
 at org.glassfish.jersey.client.ClientRuntime.invoke(ClientRuntime.java:301)
 at org.glassfish.jersey.client.JerseyInvocation.lambda$invoke$0(JerseyInvocation.java:609)
 at org.glassfish.jersey.internal.Errors.process(Errors.java:292)
 at org.glassfish.jersey.internal.Errors.process(Errors.java:274)
 at org.glassfish.jersey.internal.Errors.process(Errors.java:205)
 at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:390)
 at org.glassfish.jersey.client.JerseyInvocation.invoke(JerseyInvocation.java:608)
 at org.glassfish.jersey.client.JerseyInvocation$Builder.method(JerseyInvocation.java:421)
 at org.glassfish.jersey.client.JerseyInvocation$Builder.post(JerseyInvocation.java:327)
...

Is this expected? I could not find an example for windows machines. Thanks

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
bsideupcommented, Mar 18, 2020

@moovida well, @KostyaSha should have said that it is not supported by Bind.parse, not by the library overall.

1reaction
moovidacommented, Mar 18, 2020

@bsideup , thanks a lot for your suggestion, you made my day. It works like a charm.

Now I am puzzled about why it is said that windows paths are not supported? Maybe my usecase is super simple, as I am just executing docker commands from a desktop application locally.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why I am unable to mount a volume with a Windows Container?
I have the following simple Dockerfile: FROM mcr.microsoft.com/windows/servercore:ltsc2019 WORKDIR /azp COPY test.ps1 . CMD powershell .
Read more >
Volume mounts in windows does not work
With the mount command you should have mount points //10.0.75.2/x (assuming 10.0.75.2 to be the IpAddr of MobyLinuxVM and x=for each mapped ...
Read more >
Docker throwing Invalid Reference format exception when ...
When using the -v parameter to mount certain files in the container, I get the following exception: C:\Program Files\Docker\Docker\Resources\ ...
Read more >
Volume mounts do not work on windows 10 #77 - GitHub
Volume mounting from host won't work with that. This question is about Docker for Windows, which has host volume mounting support and is ......
Read more >
Docker for windows unable mount volume from docker vm error
I found a workaround for this issue that may help some people here. If you edit the Host Path of a mapping and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found