add mpd on genepi
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
./hardware.nix
|
||||
./immich.nix
|
||||
./monitoring
|
||||
./mpd.nix
|
||||
./network.nix
|
||||
./nginx.nix
|
||||
./persistence.nix
|
||||
|
||||
24
hosts/genepi/mpd.nix
Normal file
24
hosts/genepi/mpd.nix
Normal file
@@ -0,0 +1,24 @@
|
||||
{ config, ... }:
|
||||
{
|
||||
services.mpd = {
|
||||
enable = true;
|
||||
musicDirectory = "/home/rpqt/Media/Music";
|
||||
extraConfig = ''
|
||||
audio_output {
|
||||
type "pulse"
|
||||
name "Pulse Audio"
|
||||
}
|
||||
'';
|
||||
|
||||
network.listenAddress = "any";
|
||||
};
|
||||
|
||||
services.pulseaudio.enable = true;
|
||||
|
||||
# Workaround: run PulseAudio system-wide so that the mpd user can access it
|
||||
services.pulseaudio.systemWide = true;
|
||||
|
||||
users.users.${config.services.mpd.user}.extraGroups = [ "pulse-access" ];
|
||||
|
||||
users.users.rpqt.homeMode = "755";
|
||||
}
|
||||
Reference in New Issue
Block a user