Downloads were 403ing on two fronts: (1) recent yt-dlp needs a JS runtime to
solve YouTube's signature/nsig challenge (Deno, added in cb7a3d7), and (2) the
current yt-dlp *stable* had a bug that 403'd the android_vr client on every video
(yt-dlp#17456, fixed in nightly). Switch the backend from the stable yt-dlp
binary to nightly via pip (`--pre 'yt-dlp[default]'`). Verified end-to-end incl.
a real frontend download. No cookies / PO-token service / proxy needed.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
70 lines
3.2 KiB
YAML
70 lines
3.2 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
|
|
- SCROBBLE_URL=${SCROBBLE_URL} # play-log / stats service (setup screen)
|
|
|
|
# ── Backend (yt-dlp download server) ─────────────────────────────────────────
|
|
novasonic-backend:
|
|
image: node:22-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
|
|
- novasonic-data:/data # writable data dir for overrides, state, etc.
|
|
ports:
|
|
- "3700:3700" # route this port through your reverse proxy
|
|
environment:
|
|
- PORT=3700
|
|
- MUSIC_PATH=${MUSIC_PATH} # same path inside the container
|
|
- DATA_PATH=/data
|
|
- AUDIO_FMT=${AUDIO_FMT:-mp3}
|
|
- AUDIO_QUALITY=${AUDIO_QUALITY:-0}
|
|
- MAX_PARALLEL=${MAX_PARALLEL:-2}
|
|
- DOWNLOAD_BACKEND=${DOWNLOAD_BACKEND:-ytdlp}
|
|
- TICKETMASTER_API_KEY=${TICKETMASTER_API_KEY}
|
|
command: >
|
|
sh -c "
|
|
apt-get update && apt-get install -y --no-install-recommends python3 python3-pip ffmpeg curl git unzip && rm -rf /var/lib/apt/lists/* &&
|
|
pip install --break-system-packages -U --pre 'yt-dlp[default]' &&
|
|
curl -fsSL https://deno.land/install.sh | sh &&
|
|
pip install --break-system-packages spotapi 'git+https://github.com/TzurSoffer/spotify-downloader' &&
|
|
mkdir -p /deps && cd /deps && npm install express kuromoji &&
|
|
cd /app && PATH=/root/.deno/bin:$$PATH NODE_PATH=/deps/node_modules node novasonic-server.js
|
|
"
|
|
|
|
# ── Scrobble service (isolated timestamped play-log → stats + Wrapped) ────────
|
|
novasonic-scrobble:
|
|
image: node:22-slim
|
|
container_name: novasonic-scrobble
|
|
restart: unless-stopped
|
|
working_dir: /app
|
|
volumes:
|
|
- ./scrobble:/app:ro # server code (read-only)
|
|
- novasonic-scrobble-data:/data # own DB volume, isolated from downloads
|
|
ports:
|
|
- "3710:3710" # route this port through your reverse proxy
|
|
environment:
|
|
- PORT=3710
|
|
- DATA_PATH=/data
|
|
- NAVIDROME_URL=${NAVIDROME_URL} # for ping.view auth verification
|
|
command: >
|
|
sh -c "
|
|
mkdir -p /deps && cd /deps && npm install express &&
|
|
cd /app && NODE_PATH=/deps/node_modules node --experimental-sqlite scrobble-server.js
|
|
"
|
|
|
|
volumes:
|
|
novasonic-data: # persistent storage for romaji overrides and app state
|
|
novasonic-scrobble-data: # persistent play-log DB (novasonic-plays.db)
|