mediaserver: fix bazarr config path (YAML, not INI)
Bazarr stores its config at /var/lib/bazarr/config/config.yaml, not the old /var/lib/bazarr/data/config/config.ini path. Use yq to extract auth.apikey from the YAML. Fixes both bazarr-sync and arr-interconnect. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
d83db8c555
commit
39d5a95866
2 changed files with 5 additions and 5 deletions
|
|
@ -9,7 +9,7 @@
|
|||
# so it can reach Bazarr on localhost:6767.
|
||||
{ config, lib, pkgs, ... }:
|
||||
let
|
||||
deps = lib.makeBinPath [ pkgs.curl pkgs.jq pkgs.gnused pkgs.gnugrep pkgs.coreutils pkgs.podman ];
|
||||
deps = lib.makeBinPath [ pkgs.curl pkgs.jq pkgs.gnused pkgs.gnugrep pkgs.coreutils pkgs.podman pkgs.yq-go ];
|
||||
|
||||
# Shared preamble: extract API keys and write config.yaml
|
||||
preamble = ''
|
||||
|
|
@ -31,8 +31,8 @@ let
|
|||
RADARR_KEY=$(extract_arr_key "/var/lib/radarr/config.xml")
|
||||
|
||||
BAZARR_KEY=""
|
||||
if [ -f "/var/lib/bazarr/data/config/config.ini" ]; then
|
||||
BAZARR_KEY=$(grep -oP '(?<=apikey = ).*' /var/lib/bazarr/data/config/config.ini || true)
|
||||
if [ -f "/var/lib/bazarr/config/config.yaml" ]; then
|
||||
BAZARR_KEY=$(yq '.auth.apikey' /var/lib/bazarr/config/config.yaml || true)
|
||||
fi
|
||||
|
||||
if [ -z "$BAZARR_KEY" ]; then
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue