diff --git a/CHANGELOG.md b/CHANGELOG.md index 0177e8bf..0eb9df88 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -57,6 +57,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ### Changed - Allow `Other Video` libraries and `Image` libraries to use the same folders +- Try to mitigate inotify limit error by disabling automatic reloading of `appsettings.json` config files ### Fixed - Fix QSV acceleration in docker with older Intel devices diff --git a/ErsatzTV.Application/Troubleshooting/Queries/GetTroubleshootingInfoHandler.cs b/ErsatzTV.Application/Troubleshooting/Queries/GetTroubleshootingInfoHandler.cs index adb78308..7d516356 100644 --- a/ErsatzTV.Application/Troubleshooting/Queries/GetTroubleshootingInfoHandler.cs +++ b/ErsatzTV.Application/Troubleshooting/Queries/GetTroubleshootingInfoHandler.cs @@ -137,9 +137,14 @@ public class GetTroubleshootingInfoHandler : IRequestHandler(); foreach (DictionaryEntry de in Environment.GetEnvironmentVariables()) { - if (de is { Key: string key, Value: string value } && key.StartsWith("ETV_", StringComparison.OrdinalIgnoreCase)) + if (de is { Key: string key, Value: string value }) { - environment[key] = value; + if (key.StartsWith("ETV_", StringComparison.OrdinalIgnoreCase) + || key.StartsWith("DOTNET_", StringComparison.OrdinalIgnoreCase) + || key.StartsWith("ASPNETCORE_", StringComparison.OrdinalIgnoreCase)) + { + environment[key] = value; + } } } diff --git a/ErsatzTV.Scanner/Program.cs b/ErsatzTV.Scanner/Program.cs index 11ba8ee5..3af78e8d 100644 --- a/ErsatzTV.Scanner/Program.cs +++ b/ErsatzTV.Scanner/Program.cs @@ -64,6 +64,7 @@ public class Program try { + Environment.SetEnvironmentVariable("DOTNET_HOSTBUILDER__RELOADCONFIGONCHANGE", "false"); await CreateHostBuilder(args).Build().RunAsync(); return 0; } diff --git a/ErsatzTV/Program.cs b/ErsatzTV/Program.cs index 1d6ca156..21508f25 100644 --- a/ErsatzTV/Program.cs +++ b/ErsatzTV/Program.cs @@ -27,7 +27,7 @@ public class Program Configuration = builder .SetBasePath(BasePath) - .AddJsonFile("appsettings.json", false, true) + .AddJsonFile("appsettings.json", false, reloadOnChange: false) .AddJsonFile( $"appsettings.{Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT") ?? "Production"}.json", true) @@ -117,6 +117,7 @@ public class Program try { + Environment.SetEnvironmentVariable("DOTNET_HOSTBUILDER__RELOADCONFIGONCHANGE", "false"); await CreateHostBuilder(args).Build().RunAsync(); return 0; }