I tried Jellyfin for music but couldn't make it work with Sonos so just ended up using Sonos' local music library via SMB, with Symfonium on my phone.

It works well but it's something I'll revisit at some point as I do like the idea of one central library with shared playlists etc.

In fact, I haven't been able to even make a playlist on Sonos, it's baffling.