-
Notifications
You must be signed in to change notification settings - Fork 269
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
USB Passthrough on macOS #511
Comments
I too would like this feature, as it's already implemented in hyperkit, we just need docker for mac to add support for this. |
I also would like to use it for SDR receivers. In theory it is possible to share SDR receivers via network, but to make this work it requires to increase the network buffer size which unfortunately is also not possible, so there is no workaround. so this doesn't work in docker-compose:
see also /usr/share/doc/soapyremote-server/README.Debian and https://medium.com/mercedes-benz-techinnovation-blog/tuning-network-sysctls-in-docker-and-kubernetes-766e05da4ff2 |
Having a quick look, but it's probably not a limitation of compose; it looks like those sysctls may not be namespaced, and therefore not available within the container's namespace; you can see them when running with The docker run --rm alpine ls -l /proc/sys/net/core/
total 0
-rw-r--r-- 1 root root 0 Sep 29 08:30 somaxconn
-rw-r--r-- 1 root root 0 Sep 29 08:30 xfrm_acq_expires
-rw-r--r-- 1 root root 0 Sep 29 08:30 xfrm_aevent_etime
-rw-r--r-- 1 root root 0 Sep 29 08:30 xfrm_aevent_rseqth
-rw-r--r-- 1 root root 0 Sep 29 08:30 xfrm_larval_drop
# trying to set those systctls will fail:
docker run --rm --sysctl net.core.rmem_max=104857600 --sysctl net.core.wmem_max=104857600 alpine sh -c 'ulimit -a'
docker: Error response from daemon: failed to create task for container: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: error during container init: open /proc/sys/net/core/wmem_max: no such file or directory: unknown. With docker run --rm --network=host alpine ls -l /proc/sys/net/core/
total 0
-rw-r--r-- 1 root root 0 Sep 29 08:30 bpf_jit_enable
-rw------- 1 root root 0 Sep 29 08:30 bpf_jit_harden
-rw------- 1 root root 0 Sep 29 08:30 bpf_jit_kallsyms
-rw-r--r-- 1 root root 0 Sep 29 08:30 busy_poll
-rw-r--r-- 1 root root 0 Sep 29 08:30 busy_read
-rw-r--r-- 1 root root 0 Sep 29 08:30 default_qdisc
-rw-r--r-- 1 root root 0 Sep 29 08:30 dev_weight
-rw-r--r-- 1 root root 0 Sep 29 08:30 dev_weight_rx_bias
-rw-r--r-- 1 root root 0 Sep 29 08:30 dev_weight_tx_bias
-rw-r--r-- 1 root root 0 Sep 29 08:30 flow_limit_cpu_bitmap
-rw-r--r-- 1 root root 0 Sep 29 08:30 flow_limit_table_len
-rw-r--r-- 1 root root 0 Sep 29 08:30 max_skb_frags
-rw-r--r-- 1 root root 0 Sep 29 08:30 message_burst
-rw-r--r-- 1 root root 0 Sep 29 08:30 message_cost
-rw-r--r-- 1 root root 0 Sep 29 08:30 netdev_budget
-rw-r--r-- 1 root root 0 Sep 29 08:30 netdev_budget_usecs
-rw-r--r-- 1 root root 0 Sep 29 08:30 netdev_max_backlog
-r--r--r-- 1 root root 0 Sep 29 08:30 netdev_rss_key
-rw-r--r-- 1 root root 0 Sep 29 08:30 netdev_tstamp_prequeue
-rw-r--r-- 1 root root 0 Sep 29 08:30 optmem_max
-rw-r--r-- 1 root root 0 Sep 29 08:30 rmem_default
-rw-r--r-- 1 root root 0 Sep 29 08:30 rmem_max
-rw-r--r-- 1 root root 0 Sep 29 08:30 rps_sock_flow_entries
-rw-r--r-- 1 root root 0 Sep 29 08:30 somaxconn
-rw-r--r-- 1 root root 0 Sep 29 08:30 tstamp_allow_data
-rw-r--r-- 1 root root 0 Sep 29 08:30 warnings
-rw-r--r-- 1 root root 0 Sep 29 08:30 wmem_default
-rw-r--r-- 1 root root 0 Sep 29 08:30 wmem_max
-rw-r--r-- 1 root root 0 Sep 29 08:30 xfrm_acq_expires
-rw-r--r-- 1 root root 0 Sep 29 08:30 xfrm_aevent_etime
-rw-r--r-- 1 root root 0 Sep 29 08:30 xfrm_aevent_rseqth
-rw-r--r-- 1 root root 0 Sep 29 08:30 xfrm_larval_drop |
related thread docker/for-mac#900 |
Tell us about your request
At the suggestion of @djs55, I am creating a feature request for a macOS USB passthrough feature, which was previously discussed at:
and
Which service(s) is this request for?
Docker Desktop (macOS)
Tell us about the problem you're trying to solve. What are you trying to do, and why is it hard?
I would like to connect an SDR dongle to a docker container running on my Mac.
Are you currently working around the issue?
A recent blog post (linked in this popular StackOverflow question) describes a workaround based on installing docker in a VirtualBox.
Note: An issue has recently been opened in the
for-mac
repo:The text was updated successfully, but these errors were encountered: