change quality settings for mpd & remove slskd for now as uses too much RAM

This commit is contained in:
chaos 2024-02-08 17:47:36 +00:00
parent de89b62cab
commit 9ec2806331
No known key found for this signature in database
2 changed files with 22 additions and 18 deletions

View file

@ -58,7 +58,7 @@ in {
++ (with hosts.hetzner-arm.containers.music.profiles; [
mpd
musicSync
soulseek
#soulseek
]);
networking.firewall.allowedTCPPorts = with ports; [

View file

@ -27,12 +27,16 @@ in {
extraConfig =
''
host_permissions "127.0.0.1 read,add,control,admin"
samplerate_converter "0"
metadata_to_use "title,artist"
auto_update "yes"
audio_buffer_size "4096"
replaygain "track"
audio_output_format "44100:16:2"
audio_output_format "48000:24:2"
resampler {
plugin "soxr"
quality "very high"
threads "0"
}
''
+ concatStringsSep "\n" (forEach ["low" "medium" "high"] (quality: let
bitrates = {
@ -43,26 +47,26 @@ in {
bitrate = bitrates.${quality};
in ''
audio_output {
type "httpd"
name "HTTP Opus ${bitrate}k"
encoder "opus"
port "${toString ports."mpd-opus-${quality}"}"
bitrate "${bitrate}000"
format "44100:16:2"
always_on "yes"
tags "yes"
type "httpd"
name "http (opus-${bitrate}k) /opus/${quality}"
encoder "opus"
port "${toString ports."mpd-opus-${quality}"}"
bitrate "${bitrate}000"
format "48000:24:2"
always_on "yes"
tags "yes"
signal "music"
}
''))
+ ''
audio_output {
type "httpd"
name "HTTP FLAC"
encoder "flac"
port "${toString ports.mpd-flac}"
format "44100:16:2"
always_on "yes"
tags "yes"
type "httpd"
name "http (flac) /flac"
encoder "flac"
port "${toString ports.mpd-flac}"
format "48000:24:2"
always_on "yes"
tags "yes"
}
'';
};