From 849f0a06c8d6a755a1dab9aa4fc913563c18e070 Mon Sep 17 00:00:00 2001 From: mat Date: Wed, 4 Mar 2026 22:00:15 -0500 Subject: [PATCH] fix(dockerfile): disable TreatWarningsAsErrors for Docker publish step MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit StyleCop analyzer violations in upstream src/Jellyfin.Extensions/ block the Docker build when TreatWarningsAsErrors=true (from Directory.Build.props). Disable for container image builds — StyleCop enforcement is the CI pipeline's responsibility, not the Dockerfile's. --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index 3fed39dee..88a215664 100644 --- a/Dockerfile +++ b/Dockerfile @@ -31,11 +31,15 @@ RUN dotnet restore Jellyfin.Server/Jellyfin.Server.csproj \ # Publish the server (and all transitive dependencies, including the # PostgreSQL provider assembly added by this fork). +# Note: TreatWarningsAsErrors is disabled for the Docker build — StyleCop +# analyzer violations in upstream src/ projects would otherwise block the +# image build. StyleCop is enforced in the CI pipeline, not the Dockerfile. RUN dotnet publish Jellyfin.Server/Jellyfin.Server.csproj \ --configuration Release \ --runtime linux-x64 \ --self-contained false \ --no-restore \ + -p:TreatWarningsAsErrors=false \ --output /app # ── Runtime stage ─────────────────────────────────────────────────────────────