36 lines
880 B
Nix
36 lines
880 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
{
|
|
services.mopidy = {
|
|
enable = true;
|
|
extensionPackages = with pkgs; [ mopidy-youtube mopidy-local mopidy-mpd mopidy-mpris mopidy-iris ];
|
|
settings = {
|
|
audio = {
|
|
output = "tee name=t ! queue ! autoaudiosink t. ! audioresample ! audioconvert ! audio/x-raw,rate=48000,channels=2,format=S16LE ! filesink location=/run/snapserver/mopidy";
|
|
};
|
|
http = {
|
|
hostname = "::";
|
|
};
|
|
mpd = {
|
|
enabled = true;
|
|
hostname = "127.0.0.1";
|
|
port = 6600;
|
|
max_connections = 20;
|
|
connection_timeout = 60;
|
|
};
|
|
local = {
|
|
media_dir = "/home/ed/Music";
|
|
};
|
|
youtube = {
|
|
enabled = true;
|
|
youtube_dl_package = "yt_dlp";
|
|
allow_cache = true;
|
|
};
|
|
};
|
|
};
|
|
programs.ncmpcpp = {
|
|
enable = true;
|
|
mpdMusicDir = "~/Music";
|
|
};
|
|
}
|