elk: add elasticsearch6, logstash6, kibana6 and the beats at v6.1.0
This change is backwards compatible since the ELK tools at version 5.x remain unchanged. The test suite now both tests ELK-5 and ELK-6.
This commit is contained in:
@@ -6,6 +6,7 @@ let
|
||||
cfg = config.services.elasticsearch;
|
||||
|
||||
es5 = builtins.compareVersions (builtins.parseDrvName cfg.package.name).version "5" >= 0;
|
||||
es6 = builtins.compareVersions (builtins.parseDrvName cfg.package.name).version "6" >= 0;
|
||||
|
||||
esConfig = ''
|
||||
network.host: ${cfg.listenAddress}
|
||||
@@ -92,8 +93,6 @@ in {
|
||||
node.name: "elasticsearch"
|
||||
node.master: true
|
||||
node.data: false
|
||||
index.number_of_shards: 5
|
||||
index.number_of_replicas: 1
|
||||
'';
|
||||
};
|
||||
|
||||
@@ -165,7 +164,10 @@ in {
|
||||
path = [ pkgs.inetutils ];
|
||||
environment = {
|
||||
ES_HOME = cfg.dataDir;
|
||||
ES_JAVA_OPTS = toString ([ "-Des.path.conf=${configDir}" ] ++ cfg.extraJavaOptions);
|
||||
ES_JAVA_OPTS = toString ( optional (!es6) [ "-Des.path.conf=${configDir}" ]
|
||||
++ cfg.extraJavaOptions);
|
||||
} // optionalAttrs es6 {
|
||||
ES_PATH_CONF = configDir;
|
||||
};
|
||||
serviceConfig = {
|
||||
ExecStart = "${cfg.package}/bin/elasticsearch ${toString cfg.extraCmdLineOptions}";
|
||||
|
||||
Reference in New Issue
Block a user