fix: switch backend to node:20-slim (Debian) for glibc compatibility
tls-client (used by SpotAPI/spotdl) bundles a native .so that requires libresolv.so.2 from glibc. Alpine uses musl libc which doesn't provide this — causing spotdl to crash on import. Debian-based image has glibc. Also install yt-dlp via direct download (latest) instead of apk. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
eacd68aea7
commit
b53910ed45
1 file changed
+3
-4
+3
-4
@@ -13,7 +13,7 @@ services:
|
||||
|
||||
# ── Backend (yt-dlp download server) ─────────────────────────────────────────
|
||||
novasonic-backend:
|
||||
image: node:20-alpine
|
||||
image: node:20-slim
|
||||
container_name: novasonic-backend
|
||||
restart: unless-stopped
|
||||
working_dir: /app
|
||||
@@ -30,11 +30,10 @@ services:
|
||||
- MAX_PARALLEL=${MAX_PARALLEL:-2}
|
||||
- DOWNLOAD_BACKEND=${DOWNLOAD_BACKEND:-auto}
|
||||
- SQUID_QUALITY=${SQUID_QUALITY:-mp3}
|
||||
- SPOTIFY_CLIENT_ID=${SPOTIFY_CLIENT_ID:-}
|
||||
- SPOTIFY_CLIENT_SECRET=${SPOTIFY_CLIENT_SECRET:-}
|
||||
command: >
|
||||
sh -c "
|
||||
apk add --no-cache yt-dlp ffmpeg python3 py3-pip py3-requests git gcc musl-dev python3-dev libffi-dev &&
|
||||
apt-get update && apt-get install -y --no-install-recommends python3 python3-pip ffmpeg curl git && rm -rf /var/lib/apt/lists/* &&
|
||||
curl -sL https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp -o /usr/local/bin/yt-dlp && chmod a+rx /usr/local/bin/yt-dlp &&
|
||||
pip install --break-system-packages 'git+https://github.com/TzurSoffer/spotify-downloader' &&
|
||||
mkdir -p /deps && cd /deps && npm install express &&
|
||||
cd /app && NODE_PATH=/deps/node_modules node novasonic-server.js
|
||||
|
||||
Reference in new issue
Block a user