53 lines
2.4 KiB
YAML
53 lines
2.4 KiB
YAML
services:
|
|
ingest:
|
|
build: ./ingest
|
|
image: registry.nemunai.re/radieo/ingest
|
|
volumes:
|
|
- ./cache:/cache # volume partagé avec le stream (rw : téléchargements)
|
|
- ./state:/state # état persistant (SQLite) hors du cache éphémère
|
|
- ./config:/config:ro # config éditable sans rebuild (urls.txt yt-dlp)
|
|
environment:
|
|
- RADIEO_CACHE_DIR=/cache
|
|
- RADIEO_STATE_DIR=/state
|
|
- RADIEO_HTTP_PORT=8080
|
|
# Source Navidrome / OpenSubsonic (voir .env / .env.example).
|
|
# Laisser vide désactive la source : le stream joue alors son cache local.
|
|
- RADIEO_NAVIDROME_URL=${RADIEO_NAVIDROME_URL:-}
|
|
- RADIEO_NAVIDROME_USER=${RADIEO_NAVIDROME_USER:-}
|
|
- RADIEO_NAVIDROME_PASSWORD=${RADIEO_NAVIDROME_PASSWORD:-}
|
|
- RADIEO_NAVIDROME_PLAYLIST=${RADIEO_NAVIDROME_PLAYLIST:-}
|
|
- RADIEO_RETENTION_KEEP=${RADIEO_RETENTION_KEEP:-20}
|
|
# Source yt-dlp : liste d'URL dans config/urls.txt (créer depuis l'exemple).
|
|
- RADIEO_YTDLP_URLS_FILE=/config/urls.txt
|
|
# Source ListenBrainz : URL du feed de recommandations (ou chemin local
|
|
# sous /config, ex. /config/recommendations.xml). Vide désactive la source.
|
|
- RADIEO_LISTENBRAINZ_URL=${RADIEO_LISTENBRAINZ_URL:-}
|
|
# Dosage du mix entre les sources (0 désactive).
|
|
- RADIEO_WEIGHT_NAVIDROME=${RADIEO_WEIGHT_NAVIDROME:-3}
|
|
- RADIEO_WEIGHT_YTDLP=${RADIEO_WEIGHT_YTDLP:-1}
|
|
- RADIEO_WEIGHT_LISTENBRAINZ=${RADIEO_WEIGHT_LISTENBRAINZ:-2}
|
|
# Canonicalizer MusicBrainz (identité MBID inter-sources ; sans clé).
|
|
- RADIEO_CANONICAL_ENABLED=${RADIEO_CANONICAL_ENABLED:-1}
|
|
- RADIEO_USER_AGENT=${RADIEO_USER_AGENT:-radieo/0.1 (personal music radio)}
|
|
healthcheck:
|
|
# python-slim n'a ni curl ni wget : on sonde /healthz en Python.
|
|
test: ["CMD", "python", "-c",
|
|
"import urllib.request; urllib.request.urlopen('http://localhost:8080/healthz')"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
start_period: 10s
|
|
restart: unless-stopped
|
|
|
|
stream:
|
|
build: ./stream
|
|
image: registry.nemunai.re/radieo/stream
|
|
depends_on:
|
|
ingest:
|
|
condition: service_healthy
|
|
ports:
|
|
- "8000:8000" # flux HTTP : http://localhost:8000/radio.mp3
|
|
volumes:
|
|
- ./cache:/cache:ro # lecture seule : secours + résolution des chemins
|
|
- ./jingles:/jingles:ro # jingles intercalés toutes les 2 chansons
|
|
restart: unless-stopped
|