diff --git a/nixos/modules/services/audio/navidrome.nix b/nixos/modules/services/audio/navidrome.nix index 06d2d174a4df3..2d0381804c2a5 100644 --- a/nixos/modules/services/audio/navidrome.nix +++ b/nixos/modules/services/audio/navidrome.nix @@ -45,6 +45,12 @@ in description = "Port to run Navidrome on."; type = port; }; + + EnableInsightsCollector = mkOption { + default = false; + description = "Enable anonymous usage data collection, see for details."; + type = bool; + }; }; }; default = { }; diff --git a/pkgs/by-name/na/navidrome/package.nix b/pkgs/by-name/na/navidrome/package.nix index 8925f7ba68077..f09286b36b782 100644 --- a/pkgs/by-name/na/navidrome/package.nix +++ b/pkgs/by-name/na/navidrome/package.nix @@ -18,23 +18,23 @@ buildGo123Module rec { pname = "navidrome"; - version = "0.53.3"; + version = "0.54.3"; src = fetchFromGitHub { owner = "navidrome"; repo = "navidrome"; rev = "v${version}"; - hash = "sha256-RLmGjkeBHuvVdxXaGvlIFPI+6beAdtSLukVmwe6Hnag="; + hash = "sha256-mOJSgX+1id8tZU8KVjWbf2LycrzdudhUV/9pxKa4yHw="; }; - vendorHash = "sha256-XjiRMRfsmcw/4RLZXN36BbzbCKu98BgD3cn89e/vra4="; + vendorHash = "sha256-LpSmSbReQ3yHFvHhN/LERWQjf72/ELTjk4qhO4lyzW0="; npmRoot = "ui"; npmDeps = fetchNpmDeps { inherit src; sourceRoot = "${src.name}/ui"; - hash = "sha256-0vHInRly5xirjfV7tcYVNVLaMk4YtJeB7Ky0mrDDDnY="; + hash = "sha256-PaE1xcZX9wZRcKeqQCXbdhi4cIBWBL8ZQdww6AOB7sQ="; }; nativeBuildInputs = [ @@ -61,10 +61,18 @@ buildGo123Module rec { CGO_CFLAGS = lib.optionals stdenv.cc.isGNU [ "-Wno-return-local-addr" ]; + postPatch = '' + patchShebangs ui/bin/update-workbox.sh + ''; + preBuild = '' make buildjs ''; + tags = [ + "netgo" + ]; + postFixup = lib.optionalString ffmpegSupport '' wrapProgram $out/bin/navidrome \ --prefix PATH : ${lib.makeBinPath [ ffmpeg-headless ]}