oops
This commit is contained in:
parent
0fbe08a251
commit
c366611a09
|
@ -8,7 +8,7 @@
|
|||
}:
|
||||
|
||||
let
|
||||
server_conf = writeText "server.conf" "ghidra.repositories.dir=${directory}/repositories";
|
||||
server_conf = writeText "server.conf" "ghidra.repositories.dir=/var/lib/${directory}/repositories";
|
||||
in writeShellScriptBin "ghidra-svrAdmin" ''
|
||||
exec ${jdkPackage}/bin/java \
|
||||
-cp ${package}/lib/ghidra/Ghidra/Framework/Utility/lib/Utility.jar \
|
||||
|
|
|
@ -45,7 +45,7 @@ in {
|
|||
config = mkIf cfg.enable {
|
||||
users.users."${cfg.user}" = {
|
||||
isSystemUser = true;
|
||||
home = cfg.directory;
|
||||
home = "/var/lib/${cfg.directory}";
|
||||
inherit (cfg) group;
|
||||
packages = [ cfg.package cfg.jdkPackage ];
|
||||
};
|
||||
|
@ -63,13 +63,13 @@ in {
|
|||
paths = map head (filter isList inputSplit);
|
||||
in ghidra_home + (concatStringsSep (":" + ghidra_home) paths);
|
||||
ghidra_mainclass = "ghidra.server.remote.GhidraServer";
|
||||
ghidra_args = "-a0 -u -p${toString cfg.basePort} -ip ${cfg.host} ${cfg.directory}/repositories";
|
||||
ghidra_args = "-a0 -u -p${toString cfg.basePort} -ip ${cfg.host} /var/lib/${cfg.directory}/repositories";
|
||||
in {
|
||||
description = "Ghidra server";
|
||||
after = ["network.target"];
|
||||
serviceConfig = {
|
||||
ExecStart = "${cfg.jdkPackage}/bin/java ${ghidra_java_opt} -classpath ${ghidra_classpath} ${ghidra_mainclass} ${ghidra_args}";
|
||||
WorkingDirectory = cfg.directory;
|
||||
WorkingDirectory = "/var/lib/${cfg.directory}";
|
||||
Environment = "GHIDRA_HOME=${ghidra_home}";
|
||||
User = cfg.user;
|
||||
Group = cfg.group;
|
||||
|
|
Loading…
Reference in New Issue