2024-03-01 21:36:57 -05:00
|
|
|
{
|
|
|
|
config,
|
2024-03-05 09:27:11 -05:00
|
|
|
jellyfin-flake,
|
2024-11-22 23:15:13 -05:00
|
|
|
mainUser,
|
2024-03-01 21:36:57 -05:00
|
|
|
lib,
|
|
|
|
...
|
|
|
|
}: let
|
2024-07-24 13:26:02 -04:00
|
|
|
inherit (lib) hasAttr optionals;
|
2024-03-01 21:36:57 -05:00
|
|
|
|
|
|
|
optionalGroup = name:
|
|
|
|
optionals
|
|
|
|
(hasAttr name config.users.groups)
|
|
|
|
[config.users.groups.${name}.name];
|
|
|
|
in {
|
|
|
|
imports = [
|
|
|
|
./jfa-go.nix
|
|
|
|
./packages.nix
|
2024-03-05 09:27:11 -05:00
|
|
|
jellyfin-flake.nixosModules.default
|
2024-03-01 21:36:57 -05:00
|
|
|
];
|
|
|
|
|
|
|
|
users.users."jellyfin".extraGroups =
|
|
|
|
optionalGroup mainUser
|
|
|
|
++ optionalGroup "input"
|
|
|
|
++ optionalGroup "media"
|
2024-05-13 23:10:27 -04:00
|
|
|
++ optionalGroup "render"
|
|
|
|
++ optionalGroup "video";
|
2024-03-01 21:36:57 -05:00
|
|
|
|
2024-05-22 14:30:34 -04:00
|
|
|
services.jellyfin = {
|
|
|
|
enable = true;
|
|
|
|
|
|
|
|
settings = {
|
|
|
|
system = {
|
|
|
|
serverName = "Jelly";
|
|
|
|
quickConnectAvailable = false;
|
|
|
|
isStartupWizardCompleted = true;
|
|
|
|
|
|
|
|
enableGroupingIntoCollections = true;
|
|
|
|
enableExternalContentInSuggestions = false;
|
|
|
|
|
|
|
|
pluginRepositories = [
|
|
|
|
{
|
|
|
|
name = "Jellyfin Stable";
|
|
|
|
url = "https://repo.jellyfin.org/releases/plugin/manifest-stable.json";
|
|
|
|
}
|
|
|
|
{
|
|
|
|
name = "Intro Skipper";
|
2024-10-28 09:08:54 -04:00
|
|
|
url = "https://manifest.intro-skipper.org/manifest.json";
|
2024-05-22 14:30:34 -04:00
|
|
|
}
|
2024-05-26 15:48:19 -04:00
|
|
|
{
|
|
|
|
name = "Merge Versions Plugin";
|
|
|
|
url = "https://raw.githubusercontent.com/danieladov/JellyfinPluginManifest/master/manifest.json";
|
|
|
|
}
|
2024-05-22 14:30:34 -04:00
|
|
|
];
|
|
|
|
|
|
|
|
enableSlowResponseWarning = false;
|
|
|
|
};
|
2024-03-07 00:05:18 -05:00
|
|
|
|
2024-05-22 14:30:34 -04:00
|
|
|
branding = let
|
2024-07-24 13:26:02 -04:00
|
|
|
importFile = file: "@import url('https://cdn.jsdelivr.net/gh/CTalvio/Ultrachromic/${file}.css');";
|
2024-05-22 14:30:34 -04:00
|
|
|
in {
|
|
|
|
customCss = ''
|
|
|
|
/* Base theme */
|
2024-07-24 13:26:02 -04:00
|
|
|
${importFile "base"}
|
|
|
|
${importFile "accentlist"}
|
|
|
|
${importFile "fixes"}
|
2024-05-22 14:30:34 -04:00
|
|
|
|
2024-07-24 13:26:02 -04:00
|
|
|
${importFile "type/dark_withaccent"}
|
2024-05-22 14:30:34 -04:00
|
|
|
|
2024-07-24 13:26:02 -04:00
|
|
|
${importFile "rounding"}
|
|
|
|
${importFile "progress/floating"}
|
|
|
|
${importFile "titlepage/title_banner-logo"}
|
|
|
|
${importFile "header/header_transparent"}
|
|
|
|
${importFile "login/login_frame"}
|
|
|
|
${importFile "fields/fields_border"}
|
|
|
|
${importFile "cornerindicator/indicator_floating"}
|
2024-05-22 14:30:34 -04:00
|
|
|
|
|
|
|
/* Style backdrop */
|
|
|
|
.backdropImage {filter: blur(18px) saturate(120%) contrast(120%) brightness(40%);}
|
|
|
|
|
2024-11-11 05:33:32 -05:00
|
|
|
/* Fix Jellyfin's st**pid skip-intro placement */
|
|
|
|
.skip-button {
|
|
|
|
position: fixed;
|
|
|
|
bottom: 18%;
|
|
|
|
right: 16%;
|
|
|
|
}
|
|
|
|
|
2024-05-22 14:30:34 -04:00
|
|
|
/* Custom Settings */
|
|
|
|
:root {--accent: 145,75,245;}
|
|
|
|
:root {--rounding: 12px;}
|
|
|
|
|
|
|
|
/* https://github.com/CTalvio/Ultrachromic/issues/79 */
|
|
|
|
.skinHeader {
|
2024-07-24 13:26:02 -04:00
|
|
|
color: rgba(var(--accent), 0.8);;
|
2024-05-22 14:30:34 -04:00
|
|
|
}
|
|
|
|
.countIndicator,
|
|
|
|
.fullSyncIndicator,
|
|
|
|
.mediaSourceIndicator,
|
|
|
|
.playedIndicator {
|
2024-07-24 13:26:02 -04:00
|
|
|
background-color: rgba(var(--accent), 0.8);
|
2024-05-22 14:30:34 -04:00
|
|
|
}
|
|
|
|
'';
|
2024-03-05 09:27:11 -05:00
|
|
|
};
|
2024-03-01 21:36:57 -05:00
|
|
|
|
2024-05-22 14:30:34 -04:00
|
|
|
encoding = {
|
|
|
|
hardwareAccelerationType = "nvenc";
|
|
|
|
hardwareDecodingCodecs = [
|
|
|
|
"h264"
|
|
|
|
"hevc"
|
|
|
|
"mpeg2video"
|
|
|
|
"mpeg4"
|
|
|
|
"vc1"
|
|
|
|
"vp8"
|
|
|
|
"vp9"
|
|
|
|
"av1"
|
|
|
|
];
|
|
|
|
allowHevcEncoding = false;
|
|
|
|
enableThrottling = false;
|
|
|
|
enableTonemapping = true;
|
|
|
|
downMixAudioBoost = 1;
|
|
|
|
};
|
2024-03-01 21:36:57 -05:00
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|