Cannot access MacBook built-in bluetooth in Docker (Debian) container

I cannot access the bluetooth device built in to my MacBook Pro from my docker (debian:jessie) container. I’ve tried all of the configuration options described in other forums to run docker and they do not seem to make any difference. Here is my latest command line:

docker run --privileged --net host --security-opt seccomp=unconfined -v /Users/eugeneso/build/myProject:/myProject -i -t myProject bash

When I run hciconfig, I always get:
Can’t open HCI socket.: Address family not supported by protocol

Also there is no bluetooth folder in my /sys/class directory.

Here is my MacBook bluetooth device info:

Apple Bluetooth Software Version: 5.0.3f1
Hardware, Features, and Settings:
Name: Eugene’s MacBook Pro
Address: 6C-40-08-BF-2D-B1
Bluetooth Low Energy Supported: Yes
Handoff Supported: Yes
Instant Hot Spot Supported: Yes
Manufacturer: Broadcom
Transport: USB
Chipset: 20702B0
Firmware Version: v131 c9228
Bluetooth Power: On
Discoverable: On
Connectable: Yes
Auto Seek Pointing: On
Remote wake: On
Vendor ID: 0x05AC
Product ID: 0x8289
HCI Version: 4.0 (0x6)
HCI Revision: 0x240C
LMP Version: 4.0 (0x6)
LMP Subversion: 0x4183
Device Type (Major): Computer
Device Type (Complete): Mac Portable
Composite Class Of Device: 0x38010C
Device Class (Major): 0x01
Device Class (Minor): 0x03
Service Class: 0x1C0
Auto Seek Keyboard: On

Has anyone with a similar configuration gotten bluetooth working in the Debian container?

2 Likes

Same question over here: how can I use the macbook’s build-in bluetooth adapter from my docker container? I’ve tried running with --privileged as well as specifying the device using --device.

Question is however what the /dev/tty.* device (or other) is for the macbook’s build-in bluetooth adapter.

Thanks

Hello, I am suffering form that same issue right now,
information that I could gather up until now:
Mac built-in bluetooth device seems to be found here: /dev/cu.Bluetooth-Incoming-Port
Thought it is the incoming port and not an outgoing that we would need to scan/look for bluetooth devices (maybe I am wrong about that).
There exists a /dev/tty.Bluetooth-Incoming-Port too.
Passing these as devices to a container results in an error (might be my machine)
Waiting for an answer on docker community slack.

Same question years later, exact same things tried and same output. Is there no answer to this?

2 Likes

Same question, does it possible to configure host bluetooth device binding to container?