47 lines
926 B
Nix
47 lines
926 B
Nix
#
|
|
# Configuration for machines that should run our music server.
|
|
#
|
|
# vim: et:ts=2:sw=2:
|
|
#
|
|
{ pkgs, config, ... }:
|
|
{
|
|
#age.secrets.bandcamp.file = ./bandcamp.cfg.age;
|
|
age.secrets.subsonic = {
|
|
file = ./subsonic.cfg.age;
|
|
owner = "deprekated";
|
|
};
|
|
|
|
home-manager.users.deprekated =
|
|
{ pkgs, ... }:
|
|
{
|
|
|
|
# Use mopidy as our music server.
|
|
services.mopidy = {
|
|
enable = true;
|
|
|
|
extensionPackages = with pkgs; [
|
|
mopidy-iris
|
|
mopidy-mpd
|
|
mopidy-subidy
|
|
];
|
|
|
|
# Probvide our bandcamp authentication as an extra config file.
|
|
extraConfigFiles = [
|
|
config.age.secrets.subsonic.path
|
|
];
|
|
|
|
};
|
|
|
|
# Translate our commands over MPRIS2.
|
|
services.mpdris2 = {
|
|
enable = true;
|
|
multimediaKeys = true;
|
|
notifications = true;
|
|
|
|
# We're streaming, baby!
|
|
mpd.musicDirectory = null;
|
|
};
|
|
|
|
};
|
|
|
|
}
|