Merge pull request #197524 from f2k1de/graylog4

graylog: init at 4.0.8, 4.3.9, 5.0.2
This commit is contained in:
K900 2023-05-15 19:42:04 +03:00 committed by GitHub
commit d5c292af6b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 99 additions and 41 deletions

View File

@ -4957,6 +4957,12 @@
githubId = 25955146;
name = "eyJhb";
};
f2k1de = {
name = "f2k1de";
email = "hi@f2k1.de";
github = "f2k1de";
githubId = 11199213;
};
f4814n = {
email = "me@f4814n.de";
github = "f4814";

View File

@ -182,6 +182,8 @@ In addition to numerous new and upgraded packages, this release has the followin
- `git-bug` has been updated to at least version 0.8.0, which includes backwards incompatible changes. The `git-bug-migration` package can be used to upgrade existing repositories.
- `graylog` has been updated to version 5, which can not be upgraded directly from the previously packaged version 3.3. If you had installed the previously packaged version 3.3, please follow the [upgrade path](https://go2docs.graylog.org/5-0/upgrading_graylog/upgrade_path.htm) from 3.3 to 4.0 to 4.3 to 5.0.
- `nushell` has been updated to at least version 0.77.0, which includes potential breaking changes in aliases. The old aliases are now available as `old-alias` but it is recommended you migrate to the new format. See [Reworked aliases](https://www.nushell.sh/blog/2023-03-14-nushell_0_77.html#reworked-aliases-breaking-changes-kubouch).
- `keepassx` and `keepassx2` have been removed, due to upstream [stopping development](https://www.keepassx.org/index.html%3Fp=636.html). Consider [KeePassXC](https://keepassxc.org) as a maintained alternative.

View File

@ -37,8 +37,8 @@ in
package = mkOption {
type = types.package;
default = pkgs.graylog;
defaultText = literalExpression "pkgs.graylog";
default = if versionOlder config.system.stateVersion "23.05" then pkgs.graylog-3_3 else pkgs.graylog-5_0;
defaultText = literalExpression (if versionOlder config.system.stateVersion "23.05" then "pkgs.graylog-3_3" else "pkgs.graylog-5_0");
description = lib.mdDoc "Graylog package to use.";
};

View File

@ -0,0 +1,9 @@
{ callPackage, lib }:
let
buildGraylog = callPackage ./graylog.nix {};
in buildGraylog {
version = "3.3.16";
sha256 = "sha256-P/cnfYKnMSnDD4otEyirKlLaFduyfSO9sao4BY3c3Z4=";
maintainers = [ lib.maintainers.fadenb ];
license = lib.licenses.gpl3;
}

View File

@ -0,0 +1,9 @@
{ callPackage, lib, ...}:
let
buildGraylog = callPackage ./graylog.nix {};
in buildGraylog {
version = "4.0.8";
sha256 = "sha256-1JlJNJSU1wJiztLhYD87YM/7p3YCBXBKerEo/xfumUg=";
maintainers = [ lib.maintainers.f2k1de ];
license = lib.licenses.sspl;
}

View File

@ -0,0 +1,9 @@
{ callPackage, lib, ...}:
let
buildGraylog = callPackage ./graylog.nix {};
in buildGraylog {
version = "4.3.9";
sha256 = "sha256-BMw6U47LQQFFVM34rgadMetpYTtj6R3E+uU0dtTcH64=";
maintainers = [ lib.maintainers.f2k1de ];
license = lib.licenses.sspl;
}

View File

@ -0,0 +1,9 @@
{ callPackage, lib, ...}:
let
buildGraylog = callPackage ./graylog.nix {};
in buildGraylog {
version = "5.0.6";
sha256 = "sha256-GOxiGx2BU4x4A9W0k94gqXlhRwoixm0WK0UZN+LXkyQ=";
maintainers = [ lib.maintainers.f2k1de ];
license = lib.licenses.sspl;
}

View File

@ -1,35 +0,0 @@
{ lib, stdenv, fetchurl, makeWrapper, openjdk11_headless, nixosTests }:
stdenv.mkDerivation rec {
pname = "graylog";
version = "3.3.16";
src = fetchurl {
url = "https://packages.graylog2.org/releases/graylog/graylog-${version}.tgz";
sha256 = "sha256-P/cnfYKnMSnDD4otEyirKlLaFduyfSO9sao4BY3c3Z4=";
};
dontBuild = true;
dontStrip = true;
nativeBuildInputs = [ makeWrapper ];
makeWrapperArgs = [ "--set-default" "JAVA_HOME" "${openjdk11_headless}" ];
passthru.tests = { inherit (nixosTests) graylog; };
installPhase = ''
mkdir -p $out
cp -r {graylog.jar,lib,bin,plugin} $out
wrapProgram $out/bin/graylogctl $makeWrapperArgs
'';
meta = with lib; {
description = "Open source log management solution";
homepage = "https://www.graylog.org/";
sourceProvenance = with sourceTypes; [ binaryBytecode ];
license = licenses.gpl3;
maintainers = [ maintainers.fadenb ];
mainProgram = "graylogctl";
platforms = platforms.unix;
};
}

View File

@ -0,0 +1,41 @@
{ lib, stdenv, fetchurl, makeWrapper, openjdk11_headless, openjdk17_headless, systemd, nixosTests}:
{ version, sha256, maintainers, license }:
stdenv.mkDerivation rec {
pname = "graylog_${lib.versions.majorMinor version}";
inherit version;
src = fetchurl {
url = "https://packages.graylog2.org/releases/graylog/graylog-${version}.tgz";
inherit sha256;
};
dontBuild = true;
nativeBuildInputs = [ makeWrapper ];
makeWrapperArgs = [
"--set-default" "JAVA_HOME" "${if (lib.versionAtLeast version "5.0") then openjdk17_headless else openjdk11_headless}"
"--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ systemd ]}"
];
passthru.tests = { inherit (nixosTests) graylog; };
installPhase = ''
mkdir -p $out
cp -r {graylog.jar,bin,plugin} $out
'' + lib.optionalString (lib.versionOlder version "4.3") ''
cp -r lib $out
'' + ''
wrapProgram $out/bin/graylogctl $makeWrapperArgs
'';
meta = with lib; {
description = "Open source log management solution";
homepage = "https://www.graylog.org/";
sourceProvenance = with sourceTypes; [ binaryBytecode ];
inherit license;
inherit maintainers;
mainProgram = "graylogctl";
platforms = platforms.unix;
};
}

View File

@ -1,6 +1,6 @@
{ pkgs, lib, stdenv, fetchurl, unzip, graylog }:
{ lib, stdenv, fetchurl, unzip, graylog-5_0 }:
with pkgs.lib;
with lib;
let
glPlugin = a@{
@ -17,7 +17,7 @@ let
dontUnpack = true;
nativeBuildInputs = [ unzip ];
meta = a.meta // {
platforms = graylog.meta.platforms;
platforms = graylog-5_0.meta.platforms;
maintainers = (a.meta.maintainers or []) ++ [ maintainers.fadenb ];
sourceProvenance = with sourceTypes; [ binaryBytecode ];
};

View File

@ -641,6 +641,7 @@ mapAliases ({
grafana-mimir = throw "'grafana-mimir' has been renamed to/replaced by 'mimir'"; # Added 2022-06-07
gr-ais = gnuradio3_7.pkgs.ais; # Added 2019-05-27, changed 2020-10-16
grantlee5 = throw "'grantlee5' has been renamed to/replaced by 'libsForQt5.grantlee'"; # Converted to throw 2022-02-22
graylog = throw "graylog is now available in versions 3.3 up to 5.0. Please mind the upgrade path and choose the appropriate version. Direct upgrading from 3.3 to 4.3 or above is not supported"; # Added 2023-04-24
gr-gsm = gnuradio3_7.pkgs.gsm; # Added 2019-05-27, changed 2020-10-16
grib-api = throw "grib-api has been replaced by ecCodes => https://confluence.ecmwf.int/display/ECC/GRIB-API+migration"; # Added 2022-01-05
gringo = clingo; # added 2022-11-27

View File

@ -8112,7 +8112,14 @@ with pkgs;
grails = callPackage ../development/web/grails { jdk = null; };
graylog = callPackage ../tools/misc/graylog { };
graylog-3_3 = callPackage ../tools/misc/graylog/3.3.nix { };
graylog-4_0 = callPackage ../tools/misc/graylog/4.0.nix { };
graylog-4_3 = callPackage ../tools/misc/graylog/4.3.nix { };
graylog-5_0 = callPackage ../tools/misc/graylog/5.0.nix { };
graylogPlugins = recurseIntoAttrs (
callPackage ../tools/misc/graylog/plugins.nix { }
);