If you run BamBuddy in a container on the same machine as Home Assistant add-on and the Mosquitto broker add-on on the same HAOS box, and Bambu Studio can't connect to your Virtual Printer (connection error, TLS handshake fails) while the BamBuddy log shows MQTT port 8883 is already in use — this is a port collision on the host, not a BamBuddy bug.
Why
Bambu Studio hardcodes MQTT/TLS on port 8883 for LAN printers, so BamBuddy's Virtual Printer MQTT server needs host port 8883 (and the HA add-on runs with network_mode: host). The Mosquitto add-on also maps host 8883→8883 by default (its TLS listener). Mosquitto wins the bind, so Bambu Studio connects to Mosquitto's cert instead of the Virtual Printer CA cert → TLS verification fails.
Fix
(HA UI only — the SSH add-on's SUPERVISOR_TOKEN is read-only on the supervisor API, so this can't be scripted)
Settings → Add-ons → Mosquitto → Network.
Remap the TLS listener host port 8883 → 8885 (leave 1883/1884/8884 as-is).
Restart the Mosquitto add-on, then the BamBuddy add-on.
Verify
BamBuddy log: Simple MQTT server listening on port 8883.
openssl s_client -connect <HA-IP>:8883 returns a cert with CN=<your-VP-serial> issued by Virtual Printer CA, Verify return code: 0 (ok).
Gotcha
a Mosquitto add-on update can reset its network config to defaults and reclaim 8883, breaking the Virtual Printer again. If it recurs, just re-apply the 8883→8885 remap.