feat(configuration): set maxconcurrenttranscodes to the maximum of 4 or available CPU cores

Signed-off-by: Deluan <deluan@navidrome.org>
This commit is contained in:
Deluan 2026-03-25 08:30:44 -04:00
parent faa4acf583
commit 6fe2b76ac1

View file

@ -666,7 +666,7 @@ func setViperDefaults() {
viper.SetDefault("enablem3uexternalalbumart", false)
viper.SetDefault("enablemediafilecoverart", true)
viper.SetDefault("autotranscodedownload", false)
viper.SetDefault("maxconcurrenttranscodes", 4)
viper.SetDefault("maxconcurrenttranscodes", max(4, runtime.NumCPU()))
viper.SetDefault("defaultdownsamplingformat", consts.DefaultDownsamplingFormat)
viper.SetDefault("search.fullstring", false)
viper.SetDefault("search.backend", "fts")