138081bd8b
The NpgsqlDataSource singleton factory in AddJellyfinDbContext calls sp.GetRequiredService<IServerConfigurationManager>() to read pool settings. During ApplyStartupMigrationAsync, only a subset of services are registered in the startup service collection — IServerConfigurationManager was missing, causing a fatal DI resolution failure when DatabaseType=Jellyfin-PostgreSQL. Fix: register startupConfigurationManager as IServerConfigurationManager in the migrationStartupServiceProvider service collection. Also remove JELLYFIN_CONFIG_DIR=/config from Dockerfile.runtime ENV block. When configDir == dataDir, MakeSanityCheckOrThrow writes .jellyfin-config at the datadir root, then immediately throws because it expected .jellyfin-data. Removing the env var lets configDir default to $JELLYFIN_DATA_DIR/config.
36 lines
1.0 KiB
Docker
36 lines
1.0 KiB
Docker
# syntax=docker/dockerfile:1
|
|
# Runtime-only image — the .NET publish step runs on the CI host (runner),
|
|
# not inside this Dockerfile. This avoids DinD overlay-on-overlay I/O throttling
|
|
# which makes `dotnet publish` inside Docker-in-Docker prohibitively slow on k3s.
|
|
|
|
FROM --platform=linux/amd64 mcr.microsoft.com/dotnet/aspnet:10.0
|
|
|
|
# Install FFmpeg and native dependencies required by SkiaSharp and fontconfig.
|
|
RUN apt-get update \
|
|
&& apt-get install -y --no-install-recommends \
|
|
ffmpeg \
|
|
fontconfig \
|
|
libfontconfig1 \
|
|
libfreetype6 \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
WORKDIR /jellyfin
|
|
|
|
# Copy the pre-built publish output produced by `dotnet publish` on the CI host.
|
|
COPY publish-output/ .
|
|
|
|
# Jellyfin default ports
|
|
EXPOSE 8096
|
|
EXPOSE 8920
|
|
|
|
# Data / config volumes
|
|
VOLUME ["/config", "/cache", "/media"]
|
|
|
|
ENV JELLYFIN_DATA_DIR=/config \
|
|
JELLYFIN_CACHE_DIR=/cache \
|
|
JELLYFIN_LOG_DIR=/config/log
|
|
|
|
ENTRYPOINT ["./jellyfin", \
|
|
"--datadir", "/config", \
|
|
"--cachedir", "/cache"]
|