Merge pull request #144123 from nh2/logstash-service-jvm-options
nixos/logstash: Add logstashJvmOptionsFile option
This commit is contained in:
commit
a807630064
1 changed files with 13 additions and 0 deletions
|
@ -23,12 +23,16 @@ let
|
|||
|
||||
logstashSettingsYml = pkgs.writeText "logstash.yml" cfg.extraSettings;
|
||||
|
||||
logstashJvmOptionsFile = pkgs.writeText "jvm.options" cfg.extraJvmOptions;
|
||||
|
||||
logstashSettingsDir = pkgs.runCommand "logstash-settings" {
|
||||
inherit logstashJvmOptionsFile;
|
||||
inherit logstashSettingsYml;
|
||||
preferLocalBuild = true;
|
||||
} ''
|
||||
mkdir -p $out
|
||||
ln -s $logstashSettingsYml $out/logstash.yml
|
||||
ln -s $logstashJvmOptionsFile $out/jvm.options
|
||||
'';
|
||||
in
|
||||
|
||||
|
@ -152,6 +156,15 @@ in
|
|||
'';
|
||||
};
|
||||
|
||||
extraJvmOptions = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
description = "Extra JVM options, one per line (jvm.options format).";
|
||||
example = ''
|
||||
-Xms2g
|
||||
-Xmx2g
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue