Initiales Release: Busch-Radio Spotify Bridge v1.0.0
Stellt Spotify-Musik via Spotify Connect als HTTP-MP3-Stream bereit, den das Busch-Jäger Unterputz-Internetradio direkt abspielen kann. Komponenten: - ha-addon/: Home Assistant Add-on (librespot + ffmpeg + Icecast2) - custom_components/: Optionale HA Integration mit Media-Player-Entity - README.md: Vollständige Installations- und Konfigurationsanleitung - example-config.yaml: Kommentierte Beispielkonfiguration Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
49
ha-addon/Dockerfile
Normal file
49
ha-addon/Dockerfile
Normal file
@@ -0,0 +1,49 @@
|
||||
ARG BUILD_FROM
|
||||
|
||||
# ============================================================
|
||||
# Build stage: Librespot aus Rust-Quellcode kompilieren
|
||||
# ============================================================
|
||||
FROM rust:alpine AS librespot-builder
|
||||
|
||||
RUN apk add --no-cache \
|
||||
musl-dev \
|
||||
pkgconfig \
|
||||
openssl-dev \
|
||||
openssl-libs-static
|
||||
|
||||
# Librespot ohne Hardware-Audio-Backends kompilieren.
|
||||
# --no-default-features entfernt ALSA/PulseAudio; der Pipe-Backend
|
||||
# ist immer verfügbar und reicht für diesen Anwendungsfall.
|
||||
RUN cargo install librespot \
|
||||
--no-default-features \
|
||||
--root /install
|
||||
|
||||
# ============================================================
|
||||
# Runtime stage: HA-Basis-Image + ffmpeg + icecast
|
||||
# ============================================================
|
||||
FROM ${BUILD_FROM}
|
||||
|
||||
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
|
||||
|
||||
# Abhängigkeiten installieren
|
||||
# icecast liegt in Alpine's Community-Repository
|
||||
RUN apk add --no-cache \
|
||||
bash \
|
||||
jq \
|
||||
curl \
|
||||
python3 \
|
||||
ffmpeg \
|
||||
&& apk add --no-cache \
|
||||
--repository=https://dl-cdn.alpinelinux.org/alpine/edge/community \
|
||||
icecast \
|
||||
|| apk add --no-cache icecast
|
||||
|
||||
# Librespot-Binary aus dem Build-Stage übernehmen
|
||||
COPY --from=librespot-builder /install/bin/librespot /usr/local/bin/librespot
|
||||
RUN chmod +x /usr/local/bin/librespot
|
||||
|
||||
# Add-on Dateien kopieren
|
||||
COPY run.sh /run.sh
|
||||
RUN chmod a+x /run.sh
|
||||
|
||||
CMD ["/run.sh"]
|
||||
Reference in New Issue
Block a user