Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pass USB device into a Docker Windows Container

Tags:

docker

windows

I'm on Windows 10 using Docker for Windows. Also, I have a container which originates FROM microsoft/windowsservercore. I have an USB device attached and want to pass it to that container.

What I found so far:

Under Linux you got --device=/dev/.., but how can I accomplish this under Windows?

Michael Friis wrote on 2017-07-07 that this is currently not possible. However, this comment states that it is.

So my questions are:

  1. Is it currently possible to pass an USB device from a Windows Host into a Windows Docker container?
  2. If yes, what is the correct syntax?
  3. If not, when approximately can we expect this feature?
like image 752
JustCoding Avatar asked Sep 28 '17 10:09

JustCoding


1 Answers

You cannot directly pass USB to the container. Either you have to run Docker as a VM or use USB/IP (where the USB data is transferred as IP packets). But there will be a delay in the second method.

like image 155
kathiravan1151 Avatar answered Sep 29 '22 11:09

kathiravan1151