Fix: Icecast läuft nicht als root (changeowner nobody)
Icecast verweigert den Start als root. Lösung: - changeowner-Direktive in icecast.xml: wechselt zu nobody nach Start - Log- und Run-Verzeichnisse gehören nobody für Schreibzugriff Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -27,8 +27,10 @@ bashio::log.info "Bitrate : ${BITRATE} kbps"
|
|||||||
bashio::log.info "Stream-Port : ${STREAM_PORT}"
|
bashio::log.info "Stream-Port : ${STREAM_PORT}"
|
||||||
bashio::log.info "Stream-Pfad : ${STREAM_MOUNT}"
|
bashio::log.info "Stream-Pfad : ${STREAM_MOUNT}"
|
||||||
|
|
||||||
# ── Verzeichnisse anlegen ─────────────────────────────────────────────────────
|
# ── Verzeichnisse anlegen + Berechtigungen für nobody-User setzen ────────────
|
||||||
|
# Icecast läuft im Container als root, wechselt aber via changeowner zu nobody.
|
||||||
mkdir -p /var/log/icecast /run/icecast /tmp/busch-radio
|
mkdir -p /var/log/icecast /run/icecast /tmp/busch-radio
|
||||||
|
chown -R nobody:nobody /var/log/icecast /run/icecast /tmp/busch-radio
|
||||||
|
|
||||||
# ── Icecast-Webroot ermitteln ─────────────────────────────────────────────────
|
# ── Icecast-Webroot ermitteln ─────────────────────────────────────────────────
|
||||||
# Alpine und Debian legen Icecast in unterschiedliche Pfade
|
# Alpine und Debian legen Icecast in unterschiedliche Pfade
|
||||||
@@ -109,6 +111,11 @@ cat > /tmp/busch-radio/icecast.xml <<ICECAST_EOF
|
|||||||
|
|
||||||
<security>
|
<security>
|
||||||
<chroot>0</chroot>
|
<chroot>0</chroot>
|
||||||
|
<!-- Icecast wechselt nach dem Start zu nobody – verhindert den root-Fehler -->
|
||||||
|
<changeowner>
|
||||||
|
<user>nobody</user>
|
||||||
|
<group>nobody</group>
|
||||||
|
</changeowner>
|
||||||
</security>
|
</security>
|
||||||
</icecast>
|
</icecast>
|
||||||
ICECAST_EOF
|
ICECAST_EOF
|
||||||
|
|||||||
Reference in New Issue
Block a user