[GH-ISSUE #154] No option to configure Zeroconf port #96

Closed
opened 2026-02-28 14:25:18 +03:00 by kerem · 2 comments
Owner

Originally created by @odiroot on GitHub (Dec 19, 2024).
Original GitHub issue: https://github.com/devgianlu/go-librespot/issues/154

There is no configuration option to choose a specific Zeroconf port.
Both librespot-java and spotifyd/librespot had this option before.

Currently go-librespot is selecting a random port. It works great with Spotify Connect indeed until you run it behind a firewall.
With a firewall running (e.g. firewalld) you would have to go and update the rules for the current random port selected by go-librespot. Otherwise your instance of go-librespot is not discoverable from other Spotify-running devices.

Caveat: this still works if you use credentials storage. Because in that case go-librespot establishes its own connection to Spotify servers and "presents itself" to other devices as a sink. Still, without credential storage the service is not discoverable.

Originally created by @odiroot on GitHub (Dec 19, 2024). Original GitHub issue: https://github.com/devgianlu/go-librespot/issues/154 There is no configuration option to choose a specific Zeroconf port. Both librespot-java and spotifyd/librespot had this option before. Currently go-librespot is selecting a random port. It works great with Spotify Connect indeed until you run it behind a firewall. With a firewall running (e.g. firewalld) you would have to go and update the rules for the current random port selected by go-librespot. Otherwise your instance of go-librespot is not discoverable from other Spotify-running devices. Caveat: this still works if you use credentials storage. Because in that case go-librespot establishes its own connection to Spotify servers and "presents itself" to other devices as a sink. Still, without credential storage the service is not discoverable.
kerem 2026-02-28 14:25:18 +03:00
Author
Owner

@devgianlu commented on GitHub (Dec 20, 2024):

You're right, this was missing. I've implemented it, let me know if it works for you!

<!-- gh-comment-id:2556536850 --> @devgianlu commented on GitHub (Dec 20, 2024): You're right, this was missing. I've implemented it, let me know if it works for you!
Author
Owner

@odiroot commented on GitHub (Dec 20, 2024):

You're right, this was missing. I've implemented it, let me know if it works for you!

Thank you. Yes it does. That was quick :)

<!-- gh-comment-id:2556557144 --> @odiroot commented on GitHub (Dec 20, 2024): > You're right, this was missing. I've implemented it, let me know if it works for you! Thank you. Yes it does. That was quick :)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/go-librespot#96
No description provided.