67 lines
1.6 KiB
Nix
67 lines
1.6 KiB
Nix
{
|
|
pkgs,
|
|
lib,
|
|
config,
|
|
...
|
|
}: let
|
|
discord-plugin-wasm = pkgs.pkgsCross.wasi32.navidromePlugins.discord-rich-presence;
|
|
navidrome-skip-tests = pkgs.navidrome.overrideAttrs (oldAttrs: {
|
|
doCheck = false;
|
|
});
|
|
in {
|
|
services.navidrome = {
|
|
package = navidrome-skip-tests;
|
|
#Settings
|
|
enable = true;
|
|
openFirewall = true;
|
|
settings = {
|
|
Address = "0.0.0.0";
|
|
Port = 4533;
|
|
DataFolder = "/var/lib/navidrome";
|
|
BaseURL = "https://nv.nicknase27.com";
|
|
|
|
# Library
|
|
MusicFolder = "/mnt/media/music";
|
|
AlbumPlayCountMode = "normalized";
|
|
AutoImportPlaylists = false;
|
|
PID.Track = "musicbrainz_trackid|albumid,discnumber,tracknumber,title";
|
|
PID.Album = "musicbrainz_albumid|albumartistid,album,albumversion,musicbrainz_acoustid";
|
|
|
|
# UI / Features
|
|
DefaultTheme = "Spotify-ish";
|
|
EnableDownloads = true;
|
|
DefaultDownloadableShare = true;
|
|
EnableInsightsCollector = false;
|
|
EnableSharing = true;
|
|
EnableStarRating = true;
|
|
DefaultUIVolume = 100;
|
|
|
|
LyricsPriority = "embedded,.lrc,.txt,.srt";
|
|
|
|
LastFM.Enabled = true;
|
|
};
|
|
|
|
#Plugins
|
|
plugins = with pkgs.navidromePlugins; [
|
|
discord-plugin-wasm
|
|
];
|
|
|
|
#Environment
|
|
environmentFile = "/run/secrets/navidrome.env";
|
|
};
|
|
|
|
age.secrets.navidrome = {
|
|
file = ../../secrets/navidrome.age;
|
|
path = "/run/secrets/navidrome.env";
|
|
owner = "navidrome";
|
|
group = "navidrome";
|
|
};
|
|
|
|
systemd.services = {
|
|
navidrome = {
|
|
after = ["mnt-media.mount"];
|
|
requires = ["mnt-media.mount"];
|
|
};
|
|
};
|
|
}
|