mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-01 07:01:54 +00:00
unifi7: 7.4.156 -> 7.5.176
This commit is contained in:
parent
32663cfc65
commit
191131077b
@ -5,6 +5,10 @@ let
|
||||
stateDir = "/var/lib/unifi";
|
||||
cmd = ''
|
||||
@${cfg.jrePackage}/bin/java java \
|
||||
${optionalString (lib.versionAtLeast (lib.getVersion cfg.jrePackage) "16")
|
||||
"--add-opens java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.time=ALL-UNNAMED "
|
||||
+ "--add-opens java.base/sun.security.util=ALL-UNNAMED --add-opens java.base/java.io=ALL-UNNAMED "
|
||||
+ "--add-opens java.rmi/sun.rmi.transport=ALL-UNNAMED"} \
|
||||
${optionalString (cfg.initialJavaHeapSize != null) "-Xms${(toString cfg.initialJavaHeapSize)}m"} \
|
||||
${optionalString (cfg.maximumJavaHeapSize != null) "-Xmx${(toString cfg.maximumJavaHeapSize)}m"} \
|
||||
-jar ${stateDir}/lib/ace.jar
|
||||
@ -24,8 +28,8 @@ in
|
||||
|
||||
services.unifi.jrePackage = mkOption {
|
||||
type = types.package;
|
||||
default = if (lib.versionAtLeast (lib.getVersion cfg.unifiPackage) "7.3") then pkgs.jdk11 else pkgs.jre8;
|
||||
defaultText = literalExpression ''if (lib.versionAtLeast (lib.getVersion cfg.unifiPackage) "7.3" then pkgs.jdk11 else pkgs.jre8'';
|
||||
default = if (lib.versionAtLeast (lib.getVersion cfg.unifiPackage) "7.5") then pkgs.jdk17_headless else if (lib.versionAtLeast (lib.getVersion cfg.unifiPackage) "7.3") then pkgs.jdk11 else pkgs.jre8;
|
||||
defaultText = literalExpression ''if (lib.versionAtLeast (lib.getVersion cfg.unifiPackage) "7.5") then pkgs.jdk17_headless else if (lib.versionAtLeast (lib.getVersion cfg.unifiPackage) "7.3" then pkgs.jdk11 else pkgs.jre8'';
|
||||
description = lib.mdDoc ''
|
||||
The JRE package to use. Check the release notes to ensure it is supported.
|
||||
'';
|
||||
|
@ -66,7 +66,8 @@ in rec {
|
||||
};
|
||||
|
||||
unifi7 = generic {
|
||||
version = "7.4.156";
|
||||
sha256 = "sha256-UJjzSC2qKi2ABwH5p0s/5fXfB3NVfYBb3wBfE/8NlK4=";
|
||||
version = "7.5.176";
|
||||
suffix = "-1136930355";
|
||||
sha256 = "sha256-prsFq09zYrB74p/MGKjwvZftw78k9wbIva5xFdk+Ztw=";
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user