Is it possible to access a hardware device with a Docker image under Windows?

后端 未结 2 2142
醉话见心
醉话见心 2021-02-19 17:52

Recently, a native Docker client for Windows was released (>= Windows 7).

I wonder: is it possible to forward access to physical devices, running Windows as host

2条回答
  •  臣服心动
    2021-02-19 18:27

    This is a bad practice as it goes against the design philosophy of containers.

    If you find yourself needing access to a hardware device, it's better to consider full virtualization such as VMware, Hyper-V, KVM/QEMU, Xen and so on.

    However, the "proper" way is to design your system so that hardware is abstracted into a network service. In this way, you deploy the service to physical machines to which the hardware is attached, and call them over the network. I don't know if this is possible in your case, but such decoupling provides a significant architectural advantage.

提交回复
热议问题