Merge pull request #59206 from basvandijk/elk-6.7.1
elk: 6.5.1 -> 6.7.1
This commit is contained in:
commit
a3fb03df3e
@ -2,6 +2,8 @@
|
|||||||
config ? {},
|
config ? {},
|
||||||
pkgs ? import ../.. { inherit system config; },
|
pkgs ? import ../.. { inherit system config; },
|
||||||
enableUnfree ? false
|
enableUnfree ? false
|
||||||
|
# To run the test on the unfree ELK use the folllowing command:
|
||||||
|
# NIXPKGS_ALLOW_UNFREE=1 nix-build nixos/tests/elk.nix -A ELK-6 --arg enableUnfree true
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with import ../lib/testing.nix { inherit system pkgs; };
|
with import ../lib/testing.nix { inherit system pkgs; };
|
||||||
|
@ -4,13 +4,14 @@
|
|||||||
, makeWrapper
|
, makeWrapper
|
||||||
, fetchzip
|
, fetchzip
|
||||||
, fetchurl
|
, fetchurl
|
||||||
, nodejs
|
, nodejs-10_x
|
||||||
, coreutils
|
, coreutils
|
||||||
, which
|
, which
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with stdenv.lib;
|
with stdenv.lib;
|
||||||
let
|
let
|
||||||
|
nodejs = nodejs-10_x;
|
||||||
inherit (builtins) elemAt;
|
inherit (builtins) elemAt;
|
||||||
info = splitString "-" stdenv.hostPlatform.system;
|
info = splitString "-" stdenv.hostPlatform.system;
|
||||||
arch = elemAt info 0;
|
arch = elemAt info 0;
|
||||||
@ -18,26 +19,14 @@ let
|
|||||||
shas =
|
shas =
|
||||||
if enableUnfree
|
if enableUnfree
|
||||||
then {
|
then {
|
||||||
"x86_64-linux" = "0lip4bj3jazv83gydw99dnp03cb0fd1p4z3lvpjbisgmqffbbg5v";
|
"x86_64-linux" = "039ll00kvrp881cyybb04z90cw68j7p5cspgdxh0bky9lyi9qpwb";
|
||||||
"x86_64-darwin" = "0hjdnqagcwbjhpcfyr6w0zmy4sjnx4fyp79czb0vp7dig5arnwm3";
|
"x86_64-darwin" = "0qrakrihcjwn9dic77b0k9ja3zf6nbz534v76xid9gv20md5dds3";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
"x86_64-linux" = "1jybn4q7pz61iijzl85d948szlacfcbldn2nhhsb6063xwvf30sa";
|
"x86_64-linux" = "1v1fbmfkbnlx043z3yx02gaqqy63bj2ymvcby66n4qq0vlpahvwx";
|
||||||
"x86_64-darwin" = "1bl1h6hgp9l5cjq6pzj2x855wjaka8hbs0fn2c03lbzsc991dppr";
|
"x86_64-darwin" = "1y4q7a2b9arln94d6sj547qkv3258jlgcz9b342fh6khlbpfjb8c";
|
||||||
};
|
};
|
||||||
|
|
||||||
# For the correct phantomjs version see:
|
|
||||||
# https://github.com/elastic/kibana/blob/master/x-pack/plugins/reporting/server/browsers/phantom/paths.js
|
|
||||||
phantomjs = rec {
|
|
||||||
name = "phantomjs-${version}-linux-x86_64";
|
|
||||||
version = "2.1.1";
|
|
||||||
src = fetchzip {
|
|
||||||
inherit name;
|
|
||||||
url = "https://github.com/Medium/phantomjs/releases/download/v${version}/${name}.tar.bz2";
|
|
||||||
sha256 = "0g2dqjzr2daz6rkd6shj6rrlw55z4167vqh7bxadl8jl6jk7zbfv";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
in stdenv.mkDerivation rec {
|
in stdenv.mkDerivation rec {
|
||||||
name = "kibana-${optionalString (!enableUnfree) "oss-"}${version}";
|
name = "kibana-${optionalString (!enableUnfree) "oss-"}${version}";
|
||||||
version = elk6Version;
|
version = elk6Version;
|
||||||
@ -48,7 +37,7 @@ in stdenv.mkDerivation rec {
|
|||||||
};
|
};
|
||||||
|
|
||||||
patches = [
|
patches = [
|
||||||
# Kibana specifies it specifically needs nodejs 8.11.4 but nodejs in nixpkgs is at 8.12.0.
|
# Kibana specifies it specifically needs nodejs 10.15.2 but nodejs in nixpkgs is at 10.15.3.
|
||||||
# The <nixpkgs/nixos/tests/elk.nix> test succeeds with this newer version so lets just
|
# The <nixpkgs/nixos/tests/elk.nix> test succeeds with this newer version so lets just
|
||||||
# disable the version check.
|
# disable the version check.
|
||||||
./disable-nodejs-version-check.patch
|
./disable-nodejs-version-check.patch
|
||||||
@ -63,13 +52,6 @@ in stdenv.mkDerivation rec {
|
|||||||
makeWrapper $out/libexec/kibana/bin/kibana $out/bin/kibana \
|
makeWrapper $out/libexec/kibana/bin/kibana $out/bin/kibana \
|
||||||
--prefix PATH : "${stdenv.lib.makeBinPath [ nodejs coreutils which ]}"
|
--prefix PATH : "${stdenv.lib.makeBinPath [ nodejs coreutils which ]}"
|
||||||
sed -i 's@NODE=.*@NODE=${nodejs}/bin/node@' $out/libexec/kibana/bin/kibana
|
sed -i 's@NODE=.*@NODE=${nodejs}/bin/node@' $out/libexec/kibana/bin/kibana
|
||||||
'' +
|
|
||||||
# phantomjs is needed in the unfree version. When phantomjs doesn't exist in
|
|
||||||
# $out/libexec/kibana/data kibana will try to download and unpack it during
|
|
||||||
# runtime which will fail because the nix store is read-only. So we make sure
|
|
||||||
# it already exist in the nix store.
|
|
||||||
optionalString enableUnfree ''
|
|
||||||
ln -s ${phantomjs.src} $out/libexec/kibana/data/${phantomjs.name}
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
|
@ -8,7 +8,7 @@ let beat = package : extraArgs : buildGoPackage (rec {
|
|||||||
owner = "elastic";
|
owner = "elastic";
|
||||||
repo = "beats";
|
repo = "beats";
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
sha256 = "1qnrq9bhk7csgcxycb8c7975lq0p7cxw29i6sji777zv4hn7442m";
|
sha256 = "0n1sjngc82b7wysw5aaiqvllq4c8rx2jj7khw4vrypc40f8ahjs5";
|
||||||
};
|
};
|
||||||
|
|
||||||
goPackagePath = "github.com/elastic/beats";
|
goPackagePath = "github.com/elastic/beats";
|
||||||
|
@ -19,20 +19,20 @@ stdenv.mkDerivation (rec {
|
|||||||
url = "https://artifacts.elastic.co/downloads/elasticsearch/${name}.tar.gz";
|
url = "https://artifacts.elastic.co/downloads/elasticsearch/${name}.tar.gz";
|
||||||
sha256 =
|
sha256 =
|
||||||
if enableUnfree
|
if enableUnfree
|
||||||
then "096i8xiy7mfwlslym9mkjb2f5vqdcqhk65583526rcybqxc2zkqp"
|
then "1qh6iz3qhw8zcvxfss5w3h89zarwvk6dp5bbbag7c30kh94gkqvv"
|
||||||
else "0j3q02c4rw8272w07hm64sk5ssmj4gj8s3qigsbrq5pgf8b03fvs";
|
else "13v8qpslanfn5w81qvbg0aqh510yfbl3x59kisvdkz9ifhjbcavi";
|
||||||
};
|
};
|
||||||
|
|
||||||
patches = [ ./es-home-6.x.patch ];
|
patches = [ ./es-home-6.x.patch ];
|
||||||
|
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
substituteInPlace bin/elasticsearch-env --replace \
|
substituteInPlace bin/elasticsearch-env --replace \
|
||||||
"ES_CLASSPATH=\"\$ES_HOME/lib/\*\"" \
|
"ES_CLASSPATH=\"\$ES_HOME/lib/*\"" \
|
||||||
"ES_CLASSPATH=\"$out/lib/*\""
|
"ES_CLASSPATH=\"$out/lib/*\""
|
||||||
|
|
||||||
substituteInPlace bin/elasticsearch-cli --replace \
|
substituteInPlace bin/elasticsearch-cli --replace \
|
||||||
"ES_CLASSPATH=\"\$ES_CLASSPATH:\$ES_HOME/\$additional_classpath_directory/\*\"" \
|
"ES_CLASSPATH=\"\$ES_CLASSPATH:\$ES_HOME/\$additional_classpath_directory/*\"" \
|
||||||
"ES_CLASSPATH=\"\$ES_CLASSPATH:$out/\$additional_classpath_directory/\*\""
|
"ES_CLASSPATH=\"\$ES_CLASSPATH:$out/\$additional_classpath_directory/*\""
|
||||||
'';
|
'';
|
||||||
|
|
||||||
buildInputs = [ makeWrapper jre_headless utillinux ]
|
buildInputs = [ makeWrapper jre_headless utillinux ]
|
||||||
|
@ -27,7 +27,7 @@ in {
|
|||||||
version = "${elk6Version}";
|
version = "${elk6Version}";
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "https://github.com/vhyza/elasticsearch-analysis-lemmagen/releases/download/v${version}/${name}-plugin.zip";
|
url = "https://github.com/vhyza/elasticsearch-analysis-lemmagen/releases/download/v${version}/${name}-plugin.zip";
|
||||||
sha256 = "0299ldqwjn1gn44yyjiqjrxvs6mlclhzl1dbn6xlgg1a2lkaal4v";
|
sha256 = "0mf8lpf40bjpzfj9lkhrg7c3xinzvg7aby3vd6h92g9i676xs8ri";
|
||||||
};
|
};
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
homepage = https://github.com/vhyza/elasticsearch-analysis-lemmagen;
|
homepage = https://github.com/vhyza/elasticsearch-analysis-lemmagen;
|
||||||
@ -42,7 +42,7 @@ in {
|
|||||||
version = "${elk6Version}";
|
version = "${elk6Version}";
|
||||||
src = pkgs.fetchurl {
|
src = pkgs.fetchurl {
|
||||||
url = "https://artifacts.elastic.co/downloads/elasticsearch-plugins/discovery-ec2/discovery-ec2-${elk6Version}.zip";
|
url = "https://artifacts.elastic.co/downloads/elasticsearch-plugins/discovery-ec2/discovery-ec2-${elk6Version}.zip";
|
||||||
sha256 = "1mg9knbc4r21kaiqnmkd8nzf2i23w5zxqnxyz484q0l2jf4hlkq1";
|
sha256 = "05z4vmi29fzfqzid7fdh6h6pjwgd1dz1mhhjgjz9plpvpzymjiln";
|
||||||
};
|
};
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
homepage = https://github.com/elastic/elasticsearch/tree/master/plugins/discovery-ec2;
|
homepage = https://github.com/elastic/elasticsearch/tree/master/plugins/discovery-ec2;
|
||||||
@ -54,10 +54,10 @@ in {
|
|||||||
search_guard = esPlugin rec {
|
search_guard = esPlugin rec {
|
||||||
name = "elastic-search-guard-${version}";
|
name = "elastic-search-guard-${version}";
|
||||||
pluginName = "search-guard";
|
pluginName = "search-guard";
|
||||||
version = "${elk6Version}-23.2";
|
version = "${elk6Version}-24.3";
|
||||||
src = fetchurl rec {
|
src = fetchurl rec {
|
||||||
url = "mirror://maven/com/floragunn/search-guard-6/${version}/search-guard-6-${version}.zip";
|
url = "mirror://maven/com/floragunn/search-guard-6/${version}/search-guard-6-${version}.zip";
|
||||||
sha256 = "05310wyxzhylxr0dfgzr10pb0pak30ry8r97g49n6iqj8dw3csnb";
|
sha256 = "17gif45fbi4vj9qrzv075fkr7d2sp0naa5bjjj9gvfgqyl2flj7g";
|
||||||
};
|
};
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
homepage = https://github.com/floragunncom/search-guard;
|
homepage = https://github.com/floragunncom/search-guard;
|
||||||
|
@ -16,8 +16,8 @@ stdenv.mkDerivation rec {
|
|||||||
url = "https://artifacts.elastic.co/downloads/logstash/${name}.tar.gz";
|
url = "https://artifacts.elastic.co/downloads/logstash/${name}.tar.gz";
|
||||||
sha256 =
|
sha256 =
|
||||||
if enableUnfree
|
if enableUnfree
|
||||||
then "01mkb9fr63m3ilp4cbbjccid5m8yc7iqhnli12ynfabsf7302fdz"
|
then "18j2n6gnhfjmb6skhhrzs0d1zwa1aj9jv37rqvg4w3fimnm8p0sh"
|
||||||
else "0r60183yyywabinsv9pkd8sx0wq68h740xi3172fypjfdcqs0g9c";
|
else "181x8y6izrh587a6d1qipgj8wk71v4fggypkzjkns4my00nki42y";
|
||||||
};
|
};
|
||||||
|
|
||||||
dontBuild = true;
|
dontBuild = true;
|
||||||
|
@ -2549,7 +2549,7 @@ in
|
|||||||
|
|
||||||
# The latest version used by elasticsearch, logstash, kibana and the the beats from elastic.
|
# The latest version used by elasticsearch, logstash, kibana and the the beats from elastic.
|
||||||
elk5Version = "5.6.9";
|
elk5Version = "5.6.9";
|
||||||
elk6Version = "6.5.1";
|
elk6Version = "6.7.1";
|
||||||
|
|
||||||
elasticsearch5 = callPackage ../servers/search/elasticsearch/5.x.nix { };
|
elasticsearch5 = callPackage ../servers/search/elasticsearch/5.x.nix { };
|
||||||
elasticsearch6 = callPackage ../servers/search/elasticsearch { };
|
elasticsearch6 = callPackage ../servers/search/elasticsearch { };
|
||||||
|
Loading…
Reference in New Issue
Block a user