git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #116936 from hercules-ci/logstash-jdk
commit7d0dad76ef2e9eaf5a657710bab8d5b2e486e2da authorSandro <sandro.jaeckel@gmail.com> dateTue 30 Mar 2021, 17:22 (6 years ago) parent36a4bbd9011d59
5 files changed+36−8
nixos/modules/services/logging/logstash.nix+1−2 nixos/tests/elk.nix+1 pkgs/tools/misc/logstash/6.x.nix+11−2 pkgs/tools/misc/logstash/7.x.nix+11−2 pkgs/top-level/all-packages.nix+12−2
nixos/modules/services/logging/logstash.nix+1−2
@@ -159,10 +159,9 @@ in
159159 ###### implementation
160160
161161 config = mkIf cfg.enable {
162− systemd.services.logstash = with pkgs; {
162+ systemd.services.logstash = {
163163 description = "Logstash Daemon";
164164 wantedBy = [ "multi-user.target" ];
165− environment = { JAVA_HOME = jre; };
166165 path = [ pkgs.bash ];
167166 serviceConfig = {
168167 ExecStartPre = ''${pkgs.coreutils}/bin/mkdir -p "${cfg.dataDir}" ; ${pkgs.coreutils}/bin/chmod 700 "${cfg.dataDir}"'';
nixos/tests/elk.nix+1
@@ -120,6 +120,7 @@ let
120120 };
121121 };
122122
123+ passthru.elkPackages = elk;
123124 testScript = ''
124125 import json
125126
pkgs/tools/misc/logstash/6.x.nix+11−2
@@ -3,12 +3,13 @@
33, lib, stdenv
44, fetchurl
55, makeWrapper
6+, nixosTests
67, jre
78}:
89
910with lib;
1011
11−stdenv.mkDerivation rec {
12+let this = stdenv.mkDerivation rec {
1213 version = elk6Version;
1314 name = "logstash-${optionalString (!enableUnfree) "oss-"}${version}";
1415
@@ -52,4 +53,12 @@ stdenv.mkDerivation rec {
5253 platforms = platforms.unix;
5354 maintainers = with maintainers; [ wjlroe offline basvandijk ];
5455 };
55−}
56+ passthru.tests =
57+ optionalAttrs (!enableUnfree) (
58+ assert this.drvPath == nixosTests.elk.ELK-6.elkPackages.logstash.drvPath;
59+ {
60+ elk = nixosTests.elk.ELK-6;
61+ }
62+ );
63+};
64+in this
pkgs/tools/misc/logstash/7.x.nix+11−2
@@ -3,12 +3,13 @@
33, lib, stdenv
44, fetchurl
55, makeWrapper
6+, nixosTests
67, jre
78}:
89
910with lib;
1011
11−stdenv.mkDerivation rec {
12+let this = stdenv.mkDerivation rec {
1213 version = elk7Version;
1314 name = "logstash-${optionalString (!enableUnfree) "oss-"}${version}";
1415
@@ -52,4 +53,12 @@ stdenv.mkDerivation rec {
5253 platforms = platforms.unix;
5354 maintainers = with maintainers; [ wjlroe offline basvandijk ];
5455 };
55−}
56+ passthru.tests =
57+ optionalAttrs (!enableUnfree) (
58+ assert this.drvPath == nixosTests.elk.ELK-7.elkPackages.logstash.drvPath;
59+ {
60+ elk = nixosTests.elk.ELK-7;
61+ }
62+ );
63+};
64+in this
pkgs/top-level/all-packages.nix+12−2
@@ -5849,13 +5849,23 @@ in
58495849
58505850 lockfileProgs = callPackage ../tools/misc/lockfile-progs { };
58515851
5852− logstash6 = callPackage ../tools/misc/logstash/6.x.nix { };
5852+ logstash6 = callPackage ../tools/misc/logstash/6.x.nix {
5853+ # https://www.elastic.co/support/matrix#logstash-and-jvm
5854+ jre = jdk11_headless;
5855+ };
58535856 logstash6-oss = callPackage ../tools/misc/logstash/6.x.nix {
58545857 enableUnfree = false;
5858+ # https://www.elastic.co/support/matrix#logstash-and-jvm
5859+ jre = jdk11_headless;
5860+ };
5861+ logstash7 = callPackage ../tools/misc/logstash/7.x.nix {
5862+ # https://www.elastic.co/support/matrix#logstash-and-jvm
5863+ jre = jdk11_headless;
58555864 };
5856− logstash7 = callPackage ../tools/misc/logstash/7.x.nix { };
58575865 logstash7-oss = callPackage ../tools/misc/logstash/7.x.nix {
58585866 enableUnfree = false;
5867+ # https://www.elastic.co/support/matrix#logstash-and-jvm
5868+ jre = jdk11_headless;
58595869 };
58605870 logstash = logstash6;
58615871