2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
fetchFromGitHub,
|
|
|
|
nixosTests,
|
|
|
|
stdenv,
|
|
|
|
dotnetCorePackages,
|
|
|
|
buildDotnetModule,
|
|
|
|
ffmpeg,
|
|
|
|
fontconfig,
|
|
|
|
freetype,
|
|
|
|
jellyfin-web,
|
|
|
|
sqlite,
|
2021-05-20 23:08:51 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
buildDotnetModule rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "jellyfin";
|
2024-06-05 15:53:02 +00:00
|
|
|
version = "10.9.3"; # ensure that jellyfin-web has matching version
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-05-20 23:08:51 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "jellyfin";
|
|
|
|
repo = "jellyfin";
|
|
|
|
rev = "v${version}";
|
2024-06-05 15:53:02 +00:00
|
|
|
sha256 = "sha256-gJMz2LfxC0JXqGYNKNz1zRbWZOH1UxbcoGtmdymZ/Oo=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
propagatedBuildInputs = [ sqlite ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
projectFile = "Jellyfin.Server/Jellyfin.Server.csproj";
|
|
|
|
executables = [ "jellyfin" ];
|
|
|
|
nugetDeps = ./nuget-deps.nix;
|
|
|
|
runtimeDeps = [
|
|
|
|
ffmpeg
|
|
|
|
fontconfig
|
|
|
|
freetype
|
|
|
|
];
|
2024-05-15 15:35:15 +00:00
|
|
|
dotnet-sdk = dotnetCorePackages.sdk_8_0;
|
|
|
|
dotnet-runtime = dotnetCorePackages.aspnetcore_8_0;
|
2022-06-16 17:23:12 +00:00
|
|
|
dotnetBuildFlags = [ "--no-self-contained" ];
|
|
|
|
|
|
|
|
preInstall = ''
|
|
|
|
makeWrapperArgs+=(
|
|
|
|
--add-flags "--ffmpeg ${ffmpeg}/bin/ffmpeg"
|
2021-05-20 23:08:51 +00:00
|
|
|
--add-flags "--webdir ${jellyfin-web}/share/jellyfin-web"
|
2022-06-16 17:23:12 +00:00
|
|
|
)
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
passthru.tests = {
|
|
|
|
smoke-test = nixosTests.jellyfin;
|
|
|
|
};
|
|
|
|
|
2021-05-20 23:08:51 +00:00
|
|
|
passthru.updateScript = ./update.sh;
|
|
|
|
|
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "The Free Software Media System";
|
2020-08-20 17:08:02 +00:00
|
|
|
homepage = "https://jellyfin.org/";
|
2021-03-15 08:37:03 +00:00
|
|
|
# https://github.com/jellyfin/jellyfin/issues/610#issuecomment-537625510
|
|
|
|
license = licenses.gpl2Plus;
|
2024-06-05 15:53:02 +00:00
|
|
|
maintainers = with maintainers; [
|
|
|
|
nyanloutre
|
|
|
|
minijackson
|
|
|
|
purcell
|
|
|
|
jojosch
|
|
|
|
];
|
2024-02-29 20:09:43 +00:00
|
|
|
mainProgram = "jellyfin";
|
2022-06-16 17:23:12 +00:00
|
|
|
platforms = dotnet-runtime.meta.platforms;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|