Release v1.0.9: librespot von v0.7.0 auf main-Branch aktualisiert

v0.7.0 hat Kompatibilitätsprobleme mit Spotifys aktuellem Backend:
Spotify liefert keine Audio-Datei-IDs mehr zurück, alle Tracks
werden als "not available" gemeldet. Der main-Branch enthält Fixes.

--locked entfernt (war nur für v0.7.0 wegen vergen-Konflikt nötig).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Niklas Gühne
2026-04-07 08:49:15 +02:00
parent 15c71f1c38
commit bc5f734be4
2 changed files with 10 additions and 17 deletions

View File

@@ -12,32 +12,26 @@ RUN apk add --no-cache \
openssl-libs-static \
git
# Librespot aus dem Git-Tag klonen, patchen und kompilieren.
# Librespot vom aktuellen main-Branch klonen, patchen und kompilieren.
#
# Patch: OAuth-Server bindet an 0.0.0.0 statt 127.0.0.1.
# Standard: 127.0.0.1 → nur vom HA-Host selbst erreichbar.
# Mit 0.0.0.0 → der OAuth-Flow ist im Browser aus dem Heimnetz zugänglich.
# v0.7.0 hat Kompatibilitätsprobleme mit Spotifys aktuellem Backend:
# Spotify liefert keine Audio-Datei-IDs mehr → alle Tracks "not available".
# Der main-Branch enthält Fixes für dieses Problem.
#
# --locked: verwendet das originale Cargo.lock aus dem Tag (pinnt vergen-gitcl
# auf 0.x und vermeidet so den vergen_lib Versionskonflikt mit 9.x).
RUN git clone --depth 1 --branch v0.7.0 \
# Patches:
# 1. println! → eprintln! für "Browse to:"-URL (stdout geht sonst in ffmpeg-Pipe)
# 2. OAuth-Callback-Server auf 0.0.0.0 binden (statt nur 127.0.0.1)
# 3. Deutsche Erfolgs-Meldung nach OAuth
RUN git clone --depth 1 \
https://github.com/librespot-org/librespot.git /build && \
cd /build && \
# OAuth-Server auf allen Interfaces binden (statt nur 127.0.0.1).
# get_authcode_listener() bestimmt die Bind-Adresse aus dem redirect_uri-Parameter.
# Wir patchen den TcpListener::bind-Aufruf direkt, sodass er immer an 0.0.0.0
# bindet (mit dem gleichen Port wie im redirect_uri angegeben).
# Außerdem ersetzen wir die englische Browser-Meldung durch eine deutsche.
# Patch 1: "Browse to:"-URL auf stderr statt stdout.
# librespot schreibt die URL mit println! auf stdout, das in die ffmpeg-Pipe geht.
# eprintln! leitet auf stderr um → erscheint im HA-Log, nicht in ffmpeg.
sed -i \
-e 's/println!("Browse to: {auth_url}")/eprintln!("Browse to: {auth_url}")/' \
-e 's/println!("Provide redirect URL")/eprintln!("Provide redirect URL")/' \
oauth/src/lib.rs && \
grep -n "eprintln.*Browse to" oauth/src/lib.rs || { echo "FEHLER: println→eprintln Patch fehlgeschlagen!"; exit 1; } && \
# Patch 2: OAuth-Callback-Server auf 0.0.0.0 binden (statt nur 127.0.0.1).
# Damit ist der Callback aus dem Heimnetz erreichbar.
sed -i \
-e 's/TcpListener::bind(socket_address)/TcpListener::bind(std::net::SocketAddrV4::new(std::net::Ipv4Addr::UNSPECIFIED, socket_address.port()))/' \
-e 's/Go back to your terminal :)/Autorisierung erfolgreich! Du kannst diesen Tab schliessen./' \
@@ -45,7 +39,6 @@ RUN git clone --depth 1 --branch v0.7.0 \
grep -n "UNSPECIFIED" oauth/src/lib.rs || { echo "FEHLER: TcpListener-Patch fehlgeschlagen!"; exit 1; } && \
cargo build \
--release \
--locked \
--no-default-features \
--features "native-tls" && \
mkdir -p /install/bin && \

View File

@@ -1,6 +1,6 @@
---
name: "Busch-Radio Spotify Bridge"
version: "1.0.8"
version: "1.0.9"
slug: busch_radio_spotify
description: >
Streamt Spotify-Musik als Internet-Radio-Stream für das Busch-Jäger Unterputz-Internetradio.