api.spotify.com/v1/ aggressively rate-limits server IPs regardless of TLS fingerprint or token. SpotipyFree was already hitting the correct endpoint (api-partner.spotify.com) but crashed on KeyError: 'ownerV2' due to its own outdated field parsing — not a network block. spotapi uses the same internal GraphQL API (Spotify's web player API) which is on a separate rate-limit bucket from the public REST endpoint. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
41 lines
2.0 KiB
YAML
41 lines
2.0 KiB
YAML
services:
|
|
|
|
# ── Frontend (nginx) ──────────────────────────────────────────────────────────
|
|
novasonic-frontend:
|
|
build: .
|
|
container_name: novasonic-frontend
|
|
restart: unless-stopped
|
|
ports:
|
|
- "8080:80" # route this port through your reverse proxy
|
|
environment:
|
|
- NAVIDROME_URL=${NAVIDROME_URL} # pre-filled on the setup screen
|
|
- BACKEND_URL=${BACKEND_URL} # pre-filled on the setup screen
|
|
|
|
# ── Backend (yt-dlp download server) ─────────────────────────────────────────
|
|
novasonic-backend:
|
|
image: node:20-slim
|
|
container_name: novasonic-backend
|
|
restart: unless-stopped
|
|
working_dir: /app
|
|
volumes:
|
|
- ./backend:/app:ro # mount entire backend dir (server + lib/)
|
|
- ${MUSIC_PATH}:${MUSIC_PATH} # exact path from .env, no remapping
|
|
ports:
|
|
- "3700:3700" # route this port through your reverse proxy
|
|
environment:
|
|
- PORT=3700
|
|
- MUSIC_PATH=${MUSIC_PATH} # same path inside the container
|
|
- AUDIO_FMT=${AUDIO_FMT:-mp3}
|
|
- AUDIO_QUALITY=${AUDIO_QUALITY:-0}
|
|
- MAX_PARALLEL=${MAX_PARALLEL:-2}
|
|
- DOWNLOAD_BACKEND=${DOWNLOAD_BACKEND:-auto}
|
|
- SQUID_QUALITY=${SQUID_QUALITY:-mp3}
|
|
command: >
|
|
sh -c "
|
|
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 spotapi '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
|
|
"
|