diff options
Diffstat (limited to 'nixops/modules/mpd')
-rw-r--r-- | nixops/modules/mpd/default.nix | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/nixops/modules/mpd/default.nix b/nixops/modules/mpd/default.nix index 9e1715b..2cf37ad 100644 --- a/nixops/modules/mpd/default.nix +++ b/nixops/modules/mpd/default.nix | |||
@@ -20,6 +20,9 @@ | |||
20 | }; | 20 | }; |
21 | networking.firewall.allowedTCPPorts = [ 6600 ]; | 21 | networking.firewall.allowedTCPPorts = [ 6600 ]; |
22 | users.users.mpd.extraGroups = [ "wwwrun" "keys" ]; | 22 | users.users.mpd.extraGroups = [ "wwwrun" "keys" ]; |
23 | system.activationScripts.mpd = '' | ||
24 | install -d -m 0755 -o mpd -g mpd /run/mpd | ||
25 | ''; | ||
23 | services.mpd = { | 26 | services.mpd = { |
24 | enable = true; | 27 | enable = true; |
25 | network.listenAddress = "any"; | 28 | network.listenAddress = "any"; |
@@ -35,8 +38,7 @@ | |||
35 | type "httpd" | 38 | type "httpd" |
36 | name "OGG" | 39 | name "OGG" |
37 | encoder "vorbis" | 40 | encoder "vorbis" |
38 | port "${myconfig.env.ports.mpd_ogg}" | 41 | bind_to_address "/run/mpd/ogg.sock" |
39 | bind_to_address "127.0.0.1" | ||
40 | quality "5.0" | 42 | quality "5.0" |
41 | format "44100:16:1" | 43 | format "44100:16:1" |
42 | } | 44 | } |
@@ -44,8 +46,7 @@ | |||
44 | type "httpd" | 46 | type "httpd" |
45 | name "MP3" | 47 | name "MP3" |
46 | encoder "lame" | 48 | encoder "lame" |
47 | port "${myconfig.env.ports.mpd_mp3}" | 49 | bind_to_address "/run/mpd/mp3.sock" |
48 | bind_to_address "127.0.0.1" | ||
49 | quality "5.0" | 50 | quality "5.0" |
50 | format "44100:16:1" | 51 | format "44100:16:1" |
51 | } | 52 | } |