Compare commits
No commits in common. "d06ccea420f17454f85e2e2ff52990bd50cb4574" and "0241d4d5902a4fdc4ee981650ae9403a0fd5b51c" have entirely different histories.
d06ccea420
...
0241d4d590
|
@ -68,11 +68,11 @@ in {
|
||||||
file = "network.xml";
|
file = "network.xml";
|
||||||
content = cfg.network;
|
content = cfg.network;
|
||||||
}
|
}
|
||||||
{
|
# {
|
||||||
name = "EncodingOptions";
|
# name = "EncodingOptions";
|
||||||
file = "encoding.xml";
|
# file = "encoding.xml";
|
||||||
content = cfg.encoding;
|
# content = cfg.encoding;
|
||||||
}
|
# }
|
||||||
{
|
{
|
||||||
name = "ServerConfiguration";
|
name = "ServerConfiguration";
|
||||||
file = "system.xml";
|
file = "system.xml";
|
||||||
|
@ -96,8 +96,7 @@ in {
|
||||||
# VALUES(${user.})"
|
# VALUES(${user.})"
|
||||||
genUser = index: user: let
|
genUser = index: user: let
|
||||||
values =
|
values =
|
||||||
builtins.mapAttrs
|
builtins.mapAttrs (name: value:
|
||||||
(name: value:
|
|
||||||
if (isBool value)
|
if (isBool value)
|
||||||
then
|
then
|
||||||
if value
|
if value
|
||||||
|
@ -127,11 +126,9 @@ in {
|
||||||
if [ -n $(${sq} "SELECT 1 FROM Users WHERE Username = '${user.Username}'") ]; then
|
if [ -n $(${sq} "SELECT 1 FROM Users WHERE Username = '${user.Username}'") ]; then
|
||||||
# Create user
|
# Create user
|
||||||
${sq} "INSERT INTO Users (${concatStringsSep ","
|
${sq} "INSERT INTO Users (${concatStringsSep ","
|
||||||
(
|
(builtins.filter (x: x != "HashedPasswordFile")
|
||||||
builtins.filter (x: x != "HashedPasswordFile")
|
|
||||||
(lib.attrsets.mapAttrsToList (name: value: "${name}")
|
(lib.attrsets.mapAttrsToList (name: value: "${name}")
|
||||||
options.services.declarative-jellyfin.Users.options)
|
options.services.declarative-jellyfin.Users.options))}) \\
|
||||||
)}) \\
|
|
||||||
VALUES(${builtins.attrValues values})"
|
VALUES(${builtins.attrValues values})"
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
@ -142,14 +139,11 @@ in {
|
||||||
''
|
''
|
||||||
mkdir -p ${path}
|
mkdir -p ${path}
|
||||||
# Make sure there is a database
|
# Make sure there is a database
|
||||||
if [ -z "${path}/${dbname}" ]; then
|
if [ -z "${path}/${dbname}" ] && cp ${defaultDB} "${path}/${dbname}"
|
||||||
cp ${defaultDB} "${path}/${dbname}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
maxIndex=$(${sq} 'SELECT InternalId FROM Users ORDER BY InternalId DESC LIMIT 1')
|
maxIndex=$(${sq} 'SELECT InternalId FROM Users ORDER BY InternalId DESC LIMIT 1')
|
||||||
if [ -n "$maxIndex" ]; then
|
if [ -n "$maxIndex" ] && maxIndex="1"
|
||||||
maxIndex="1"
|
|
||||||
fi
|
|
||||||
|
|
||||||
''
|
''
|
||||||
);
|
);
|
||||||
|
|
|
@ -1,10 +1,6 @@
|
||||||
{
|
{lib, ...}:
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; {
|
with lib; {
|
||||||
options.services.declarative-jellyfin.encoding = {
|
options.service.declarative-jellyfin.encoding = {
|
||||||
EncodingThreadCount = mkOption {
|
EncodingThreadCount = mkOption {
|
||||||
type = types.int;
|
type = types.int;
|
||||||
default = -1;
|
default = -1;
|
||||||
|
@ -22,7 +18,7 @@ with lib; {
|
||||||
EnableFallbackFont = mkEnableOption "Enable fallback font";
|
EnableFallbackFont = mkEnableOption "Enable fallback font";
|
||||||
EnableAudioVbr = mkEnableOption "Enable VBR Audio";
|
EnableAudioVbr = mkEnableOption "Enable VBR Audio";
|
||||||
DownMixAudioBoost = mkOption {
|
DownMixAudioBoost = mkOption {
|
||||||
type = types.number;
|
type = types.float;
|
||||||
default = 2;
|
default = 2;
|
||||||
description = "Boost audio when downmixing. A value of one will preserve the original volume.";
|
description = "Boost audio when downmixing. A value of one will preserve the original volume.";
|
||||||
};
|
};
|
||||||
|
@ -130,7 +126,7 @@ with lib; {
|
||||||
default = "auto";
|
default = "auto";
|
||||||
};
|
};
|
||||||
TonemappingDesat = mkOption {
|
TonemappingDesat = mkOption {
|
||||||
type = types.number;
|
type = types.float;
|
||||||
description = ''
|
description = ''
|
||||||
Apply desaturation for highlights that exceed this level of brightness.
|
Apply desaturation for highlights that exceed this level of brightness.
|
||||||
The higher the parameter, the more color information will be preserved.
|
The higher the parameter, the more color information will be preserved.
|
||||||
|
@ -142,7 +138,7 @@ with lib; {
|
||||||
default = 0;
|
default = 0;
|
||||||
};
|
};
|
||||||
TonemappingPeak = mkOption {
|
TonemappingPeak = mkOption {
|
||||||
type = types.number;
|
type = types.float;
|
||||||
description = ''
|
description = ''
|
||||||
Override signal/nominal/reference peak with this value.
|
Override signal/nominal/reference peak with this value.
|
||||||
Useful when the embedded peak information in display metadata is not reliable or when tone mapping from a lower range to a higher range.
|
Useful when the embedded peak information in display metadata is not reliable or when tone mapping from a lower range to a higher range.
|
||||||
|
@ -152,7 +148,7 @@ with lib; {
|
||||||
default = 100;
|
default = 100;
|
||||||
};
|
};
|
||||||
TonemapingParam = mkOption {
|
TonemapingParam = mkOption {
|
||||||
type = types.number;
|
type = types.float;
|
||||||
description = ''
|
description = ''
|
||||||
Tune the tone mapping algorithm.
|
Tune the tone mapping algorithm.
|
||||||
The recommended and default values are 0.
|
The recommended and default values are 0.
|
||||||
|
@ -162,7 +158,7 @@ with lib; {
|
||||||
default = 0;
|
default = 0;
|
||||||
};
|
};
|
||||||
VppTonemappingBrightness = mkOption {
|
VppTonemappingBrightness = mkOption {
|
||||||
type = types.number;
|
type = types.float;
|
||||||
description = ''
|
description = ''
|
||||||
Apply brightness gain in VPP tone mapping.
|
Apply brightness gain in VPP tone mapping.
|
||||||
|
|
||||||
|
@ -171,7 +167,7 @@ with lib; {
|
||||||
default = 16;
|
default = 16;
|
||||||
};
|
};
|
||||||
VppTonemappingContrast = mkOption {
|
VppTonemappingContrast = mkOption {
|
||||||
type = types.number;
|
type = types.float;
|
||||||
description = ''
|
description = ''
|
||||||
Apply contrast gain in VPP tone mapping.
|
Apply contrast gain in VPP tone mapping.
|
||||||
|
|
||||||
|
@ -282,7 +278,7 @@ with lib; {
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
AllowOnDemandMetadataBasedKeyframeExtractionForExtensions = mkOption {
|
AllowOnDemandMetadataBasedKeyframeExtractionForExtensions = mkOption {
|
||||||
type = with types; listOf str;
|
type = types.listOf str;
|
||||||
description = "imma be real i have no idea what this option is. Just leave it as the default";
|
description = "imma be real i have no idea what this option is. Just leave it as the default";
|
||||||
default = ["mkv"];
|
default = ["mkv"];
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue