Don't log api keys

This commit is contained in:
pcjones
2024-02-12 02:31:36 +01:00
parent 27ba8a1f19
commit 8df44d514f
2 changed files with 25 additions and 4 deletions

View File

@@ -33,6 +33,18 @@ internal class Program
//options.SizeLimit = 20000; //options.SizeLimit = 20000;
}); });
// TODO workaround to not log api keys
builder.Logging.AddFilter((category, level) =>
{
// Prevent logging of HTTP request and response if the category is HttpClient
if (category.Contains("System.Net.Http.HttpClient"))
{
return false;
}
return true;
});
builder.Services.AddControllers(); builder.Services.AddControllers();
builder.Services.AddHostedService<ArrSyncBackgroundService>(); builder.Services.AddHostedService<ArrSyncBackgroundService>();
builder.Services.AddSingleton<TitleApiService>(); // TODO rename builder.Services.AddSingleton<TitleApiService>(); // TODO rename

View File

@@ -1,9 +1,18 @@
version: '3.8' version: '3.8'
services: services:
umlautadaptarr: umlautadaptarr:
build: . build: https://github.com/PCJones/UmlautAdaptarr.git#master
image: umlautadaptarr
restart: unless-stopped
networks:
- local
environment: environment:
SONARR_HOST: "http://localhost:8989" - PUID=${ENV_PUID}
SONARR_API_KEY: "" - PGID=${ENV_PGID}
- TZ=${TIMEZONE}
environment:
SONARR_HOST: "http://sonarr:8989"
SONARR_API_KEY: ${SONARR_API_KEY}
ports: ports:
- "5005:5005" - "5005:5005"