Zabbix: Add LTS version 7 (#332290)

authored by Aaron Andersen and committed by GitHub e507ac8a 32dddf66

+222 -105
+12 -7
pkgs/by-name/za/zabbix-agent2-plugin-postgresql/package.nix
··· 1 - { lib, buildGoModule, fetchurl }: 2 3 buildGoModule rec { 4 pname = "zabbix-agent2-plugin-postgresql"; 5 - version = "6.4.15"; 6 7 src = fetchurl { 8 url = "https://cdn.zabbix.com/zabbix-agent2-plugins/sources/postgresql/zabbix-agent2-plugin-postgresql-${version}.tar.gz"; 9 - hash = "sha256-9N2xN7ckfBiwWcI+C4VeHDQVrWEaeKUcjfIw7GU7K9E="; 10 }; 11 12 vendorHash = null; 13 14 - meta = with lib; { 15 description = "Required tool for Zabbix agent integrated PostgreSQL monitoring"; 16 mainProgram = "postgresql"; 17 homepage = "https://www.zabbix.com/integrations/postgresql"; 18 - license = licenses.asl20; 19 - maintainers = with maintainers; [ gador ]; 20 - platforms = platforms.linux; 21 }; 22 }
··· 1 + { 2 + lib, 3 + buildGoModule, 4 + fetchurl, 5 + }: 6 7 buildGoModule rec { 8 pname = "zabbix-agent2-plugin-postgresql"; 9 + version = "7.0.2"; 10 11 src = fetchurl { 12 url = "https://cdn.zabbix.com/zabbix-agent2-plugins/sources/postgresql/zabbix-agent2-plugin-postgresql-${version}.tar.gz"; 13 + hash = "sha256-2+P0a74flxWIpZaII+V04G/szFUrnnIy+f8LfDewcx0="; 14 }; 15 16 vendorHash = null; 17 18 + meta = { 19 description = "Required tool for Zabbix agent integrated PostgreSQL monitoring"; 20 mainProgram = "postgresql"; 21 homepage = "https://www.zabbix.com/integrations/postgresql"; 22 + license = 23 + if (lib.versions.major version >= "7") then lib.licenses.agpl3Only else lib.licenses.gpl2Plus; 24 + maintainers = with lib.maintainers; [ gador ]; 25 + platforms = lib.platforms.linux; 26 }; 27 }
+19 -5
pkgs/servers/monitoring/zabbix/agent.nix
··· 1 - { lib, stdenv, fetchurl, pkg-config, libiconv, openssl, pcre }: 2 3 - import ./versions.nix ({ version, hash, ... }: 4 stdenv.mkDerivation { 5 pname = "zabbix-agent"; 6 inherit version; ··· 36 meta = { 37 description = "Enterprise-class open source distributed monitoring solution (client-side agent)"; 38 homepage = "https://www.zabbix.com/"; 39 - license = lib.licenses.gpl2Plus; 40 - maintainers = with lib.maintainers; [ mmahut psyanticy ]; 41 platforms = lib.platforms.unix; 42 }; 43 - })
··· 1 + { 2 + lib, 3 + stdenv, 4 + fetchurl, 5 + pkg-config, 6 + libiconv, 7 + openssl, 8 + pcre, 9 + }: 10 11 + import ./versions.nix ( 12 + { version, hash, ... }: 13 stdenv.mkDerivation { 14 pname = "zabbix-agent"; 15 inherit version; ··· 45 meta = { 46 description = "Enterprise-class open source distributed monitoring solution (client-side agent)"; 47 homepage = "https://www.zabbix.com/"; 48 + license = 49 + if (lib.versions.major version >= "7") then lib.licenses.agpl3Only else lib.licenses.gpl2Plus; 50 + maintainers = with lib.maintainers; [ 51 + mmahut 52 + psyanticy 53 + ]; 54 platforms = lib.platforms.unix; 55 }; 56 + } 57 + )
+32 -6
pkgs/servers/monitoring/zabbix/agent2.nix
··· 1 - { lib, buildGoModule, fetchurl, autoreconfHook, pkg-config, libiconv, openssl, pcre, zlib }: 2 3 - import ./versions.nix ({ version, hash, vendorHash ? throw "unsupported version ${version} for zabbix-agent2", ... }: 4 buildGoModule { 5 pname = "zabbix-agent2"; 6 inherit version; ··· 14 15 inherit vendorHash; 16 17 - nativeBuildInputs = [ autoreconfHook pkg-config ]; 18 - buildInputs = [ libiconv openssl pcre zlib ]; 19 20 inherit (buildGoModule.go) GOOS GOARCH; 21 ··· 59 meta = { 60 description = "Enterprise-class open source distributed monitoring solution (client-side agent)"; 61 homepage = "https://www.zabbix.com/"; 62 - license = lib.licenses.gpl2Plus; 63 maintainers = with lib.maintainers; [ aanderse ]; 64 platforms = lib.platforms.unix; 65 }; 66 - })
··· 1 + { 2 + lib, 3 + buildGoModule, 4 + fetchurl, 5 + autoreconfHook, 6 + pkg-config, 7 + libiconv, 8 + openssl, 9 + pcre, 10 + zlib, 11 + }: 12 13 + import ./versions.nix ( 14 + { 15 + version, 16 + hash, 17 + vendorHash ? throw "unsupported version ${version} for zabbix-agent2", 18 + ... 19 + }: 20 buildGoModule { 21 pname = "zabbix-agent2"; 22 inherit version; ··· 30 31 inherit vendorHash; 32 33 + nativeBuildInputs = [ 34 + autoreconfHook 35 + pkg-config 36 + ]; 37 + buildInputs = [ 38 + libiconv 39 + openssl 40 + pcre 41 + zlib 42 + ]; 43 44 inherit (buildGoModule.go) GOOS GOARCH; 45 ··· 83 meta = { 84 description = "Enterprise-class open source distributed monitoring solution (client-side agent)"; 85 homepage = "https://www.zabbix.com/"; 86 + license = 87 + if (lib.versions.major version >= "7") then lib.licenses.agpl3Only else lib.licenses.gpl2Plus; 88 maintainers = with lib.maintainers; [ aanderse ]; 89 platforms = lib.platforms.unix; 90 }; 91 + } 92 + )
+61 -37
pkgs/servers/monitoring/zabbix/proxy.nix
··· 1 - { lib, stdenv, fetchurl, pkg-config, libevent, libiconv, openssl, pcre, zlib 2 - , odbcSupport ? true, unixODBC 3 - , snmpSupport ? stdenv.buildPlatform == stdenv.hostPlatform, net-snmp 4 - , sshSupport ? true, libssh2 5 - , sqliteSupport ? false, sqlite 6 - , mysqlSupport ? false, libmysqlclient 7 - , postgresqlSupport ? false, postgresql 8 }: 9 10 # ensure exactly one database type is selected ··· 15 let 16 inherit (lib) optional optionalString; 17 in 18 - import ./versions.nix ({ version, hash, ... }: 19 - stdenv.mkDerivation { 20 - pname = "zabbix-proxy"; 21 - inherit version; 22 23 - src = fetchurl { 24 - url = "https://cdn.zabbix.com/zabbix/sources/stable/${lib.versions.majorMinor version}/zabbix-${version}.tar.gz"; 25 - inherit hash; 26 - }; 27 28 - nativeBuildInputs = [ pkg-config ]; 29 - buildInputs = [ 30 libevent 31 libiconv 32 openssl ··· 40 ++ optional mysqlSupport libmysqlclient 41 ++ optional postgresqlSupport postgresql; 42 43 - configureFlags = [ 44 "--enable-ipv6" 45 "--enable-proxy" 46 "--with-iconv" ··· 56 ++ optional mysqlSupport "--with-mysql" 57 ++ optional postgresqlSupport "--with-postgresql"; 58 59 - prePatch = '' 60 - find database -name data.sql -exec sed -i 's|/usr/bin/||g' {} + 61 - ''; 62 63 - makeFlags = [ 64 - "AR:=$(AR)" 65 - "RANLIB:=$(RANLIB)" 66 - ]; 67 68 - postInstall = '' 69 mkdir -p $out/share/zabbix/database/ 70 - '' + optionalString sqliteSupport '' 71 mkdir -p $out/share/zabbix/database/sqlite3 72 cp -prvd database/sqlite3/schema.sql $out/share/zabbix/database/sqlite3/ 73 - '' + optionalString mysqlSupport '' 74 mkdir -p $out/share/zabbix/database/mysql 75 cp -prvd database/mysql/schema.sql $out/share/zabbix/database/mysql/ 76 - '' + optionalString postgresqlSupport '' 77 mkdir -p $out/share/zabbix/database/postgresql 78 cp -prvd database/postgresql/schema.sql $out/share/zabbix/database/postgresql/ 79 ''; 80 81 - meta = with lib; { 82 - description = "Enterprise-class open source distributed monitoring solution (client-server proxy)"; 83 - homepage = "https://www.zabbix.com/"; 84 - license = licenses.gpl2Plus; 85 - maintainers = [ maintainers.mmahut ]; 86 - platforms = platforms.linux; 87 - }; 88 - })
··· 1 + { 2 + lib, 3 + stdenv, 4 + fetchurl, 5 + pkg-config, 6 + libevent, 7 + libiconv, 8 + openssl, 9 + pcre, 10 + zlib, 11 + odbcSupport ? true, 12 + unixODBC, 13 + snmpSupport ? stdenv.buildPlatform == stdenv.hostPlatform, 14 + net-snmp, 15 + sshSupport ? true, 16 + libssh2, 17 + sqliteSupport ? false, 18 + sqlite, 19 + mysqlSupport ? false, 20 + libmysqlclient, 21 + postgresqlSupport ? false, 22 + postgresql, 23 }: 24 25 # ensure exactly one database type is selected ··· 30 let 31 inherit (lib) optional optionalString; 32 in 33 + import ./versions.nix ( 34 + { version, hash, ... }: 35 + stdenv.mkDerivation { 36 + pname = "zabbix-proxy"; 37 + inherit version; 38 39 + src = fetchurl { 40 + url = "https://cdn.zabbix.com/zabbix/sources/stable/${lib.versions.majorMinor version}/zabbix-${version}.tar.gz"; 41 + inherit hash; 42 + }; 43 44 + nativeBuildInputs = [ pkg-config ]; 45 + buildInputs = 46 + [ 47 libevent 48 libiconv 49 openssl ··· 57 ++ optional mysqlSupport libmysqlclient 58 ++ optional postgresqlSupport postgresql; 59 60 + configureFlags = 61 + [ 62 "--enable-ipv6" 63 "--enable-proxy" 64 "--with-iconv" ··· 74 ++ optional mysqlSupport "--with-mysql" 75 ++ optional postgresqlSupport "--with-postgresql"; 76 77 + prePatch = '' 78 + find database -name data.sql -exec sed -i 's|/usr/bin/||g' {} + 79 + ''; 80 81 + makeFlags = [ 82 + "AR:=$(AR)" 83 + "RANLIB:=$(RANLIB)" 84 + ]; 85 86 + postInstall = 87 + '' 88 mkdir -p $out/share/zabbix/database/ 89 + '' 90 + + optionalString sqliteSupport '' 91 mkdir -p $out/share/zabbix/database/sqlite3 92 cp -prvd database/sqlite3/schema.sql $out/share/zabbix/database/sqlite3/ 93 + '' 94 + + optionalString mysqlSupport '' 95 mkdir -p $out/share/zabbix/database/mysql 96 cp -prvd database/mysql/schema.sql $out/share/zabbix/database/mysql/ 97 + '' 98 + + optionalString postgresqlSupport '' 99 mkdir -p $out/share/zabbix/database/postgresql 100 cp -prvd database/postgresql/schema.sql $out/share/zabbix/database/postgresql/ 101 ''; 102 103 + meta = { 104 + description = "Enterprise-class open source distributed monitoring solution (client-server proxy)"; 105 + homepage = "https://www.zabbix.com/"; 106 + license = 107 + if (lib.versions.major version >= "7") then lib.licenses.agpl3Only else lib.licenses.gpl2Plus; 108 + maintainers = with lib.maintainers; [ mmahut ]; 109 + platforms = lib.platforms.linux; 110 + }; 111 + } 112 + )
+74 -40
pkgs/servers/monitoring/zabbix/server.nix
··· 1 - { lib, stdenv, fetchurl, autoreconfHook, pkg-config, curl, libevent, libiconv, libxml2, openssl, pcre, zlib 2 - , jabberSupport ? true, iksemel 3 - , ldapSupport ? true, openldap 4 - , odbcSupport ? true, unixODBC 5 - , snmpSupport ? true, net-snmp 6 - , sshSupport ? true, libssh2 7 - , mysqlSupport ? false, libmysqlclient 8 - , postgresqlSupport ? false, postgresql 9 - , ipmiSupport ? false, openipmi 10 }: 11 12 # ensure exactly one primary database type is selected ··· 16 let 17 inherit (lib) optional optionalString; 18 in 19 - import ./versions.nix ({ version, hash, ... }: 20 - stdenv.mkDerivation { 21 - pname = "zabbix-server"; 22 - inherit version; 23 24 - src = fetchurl { 25 - url = "https://cdn.zabbix.com/zabbix/sources/stable/${lib.versions.majorMinor version}/zabbix-${version}.tar.gz"; 26 - inherit hash; 27 - }; 28 29 - nativeBuildInputs = [ autoreconfHook pkg-config ]; 30 - buildInputs = [ 31 curl 32 libevent 33 libiconv ··· 45 ++ optional postgresqlSupport postgresql 46 ++ optional ipmiSupport openipmi; 47 48 - configureFlags = [ 49 "--enable-ipv6" 50 "--enable-server" 51 "--with-iconv" ··· 65 ++ optional postgresqlSupport "--with-postgresql" 66 ++ optional ipmiSupport "--with-openipmi=${openipmi.dev}"; 67 68 - prePatch = '' 69 - find database -name data.sql -exec sed -i 's|/usr/bin/||g' {} + 70 - ''; 71 72 - preAutoreconf = '' 73 - for i in $(find . -type f -name "*.m4"); do 74 - substituteInPlace $i \ 75 - --replace 'test -x "$PKG_CONFIG"' 'type -P "$PKG_CONFIG" >/dev/null' 76 - done 77 - ''; 78 79 - postInstall = '' 80 mkdir -p $out/share/zabbix/database/ 81 cp -r include $out/ 82 - '' + optionalString mysqlSupport '' 83 mkdir -p $out/share/zabbix/database/mysql 84 cp -prvd database/mysql/*.sql $out/share/zabbix/database/mysql/ 85 - '' + optionalString postgresqlSupport '' 86 mkdir -p $out/share/zabbix/database/postgresql 87 cp -prvd database/postgresql/*.sql $out/share/zabbix/database/postgresql/ 88 ''; 89 90 - meta = with lib; { 91 - description = "Enterprise-class open source distributed monitoring solution"; 92 - homepage = "https://www.zabbix.com/"; 93 - license = licenses.gpl2Plus; 94 - maintainers = with maintainers; [ mmahut psyanticy ]; 95 - platforms = platforms.linux; 96 - }; 97 - })
··· 1 + { 2 + lib, 3 + stdenv, 4 + fetchurl, 5 + autoreconfHook, 6 + pkg-config, 7 + curl, 8 + libevent, 9 + libiconv, 10 + libxml2, 11 + openssl, 12 + pcre, 13 + zlib, 14 + jabberSupport ? true, 15 + iksemel, 16 + ldapSupport ? true, 17 + openldap, 18 + odbcSupport ? true, 19 + unixODBC, 20 + snmpSupport ? true, 21 + net-snmp, 22 + sshSupport ? true, 23 + libssh2, 24 + mysqlSupport ? false, 25 + libmysqlclient, 26 + postgresqlSupport ? false, 27 + postgresql, 28 + ipmiSupport ? false, 29 + openipmi, 30 }: 31 32 # ensure exactly one primary database type is selected ··· 36 let 37 inherit (lib) optional optionalString; 38 in 39 + import ./versions.nix ( 40 + { version, hash, ... }: 41 + stdenv.mkDerivation { 42 + pname = "zabbix-server"; 43 + inherit version; 44 45 + src = fetchurl { 46 + url = "https://cdn.zabbix.com/zabbix/sources/stable/${lib.versions.majorMinor version}/zabbix-${version}.tar.gz"; 47 + inherit hash; 48 + }; 49 50 + nativeBuildInputs = [ 51 + autoreconfHook 52 + pkg-config 53 + ]; 54 + buildInputs = 55 + [ 56 curl 57 libevent 58 libiconv ··· 70 ++ optional postgresqlSupport postgresql 71 ++ optional ipmiSupport openipmi; 72 73 + configureFlags = 74 + [ 75 "--enable-ipv6" 76 "--enable-server" 77 "--with-iconv" ··· 91 ++ optional postgresqlSupport "--with-postgresql" 92 ++ optional ipmiSupport "--with-openipmi=${openipmi.dev}"; 93 94 + prePatch = '' 95 + find database -name data.sql -exec sed -i 's|/usr/bin/||g' {} + 96 + ''; 97 98 + preAutoreconf = '' 99 + for i in $(find . -type f -name "*.m4"); do 100 + substituteInPlace $i \ 101 + --replace 'test -x "$PKG_CONFIG"' 'type -P "$PKG_CONFIG" >/dev/null' 102 + done 103 + ''; 104 105 + postInstall = 106 + '' 107 mkdir -p $out/share/zabbix/database/ 108 cp -r include $out/ 109 + '' 110 + + optionalString mysqlSupport '' 111 mkdir -p $out/share/zabbix/database/mysql 112 cp -prvd database/mysql/*.sql $out/share/zabbix/database/mysql/ 113 + '' 114 + + optionalString postgresqlSupport '' 115 mkdir -p $out/share/zabbix/database/postgresql 116 cp -prvd database/postgresql/*.sql $out/share/zabbix/database/postgresql/ 117 ''; 118 119 + meta = { 120 + description = "Enterprise-class open source distributed monitoring solution"; 121 + homepage = "https://www.zabbix.com/"; 122 + license = 123 + if (lib.versions.major version >= "7") then lib.licenses.agpl3Only else lib.licenses.gpl2Plus; 124 + maintainers = with lib.maintainers; [ 125 + mmahut 126 + psyanticy 127 + ]; 128 + platforms = lib.platforms.linux; 129 + }; 130 + } 131 + )
+5
pkgs/servers/monitoring/zabbix/versions.nix
··· 1 generic: { 2 v64 = generic { 3 version = "6.4.15"; 4 hash = "sha256-CtmNCuzDVchijinWcop3lGUTVGS2JbiQCbmusyXBQvY=";
··· 1 generic: { 2 + v70 = generic { 3 + version = "7.0.2"; 4 + hash = "sha256-QnlBW8zvcuyF+fmrIf/o43Mf61volBYReReADpRfoYA="; 5 + vendorHash = null; 6 + }; 7 v64 = generic { 8 version = "6.4.15"; 9 hash = "sha256-CtmNCuzDVchijinWcop3lGUTVGS2JbiQCbmusyXBQvY=";
+18 -10
pkgs/servers/monitoring/zabbix/web.nix
··· 1 - { lib, stdenv, fetchurl, writeText }: 2 3 - import ./versions.nix ({ version, hash, ... }: 4 stdenv.mkDerivation rec { 5 pname = "zabbix-web"; 6 inherit version; ··· 11 }; 12 13 phpConfig = writeText "zabbix.conf.php" '' 14 - <?php 15 - return require(getenv('ZABBIX_CONFIG')); 16 - ?> 17 ''; 18 19 installPhase = '' ··· 22 cp ${phpConfig} $out/share/zabbix/conf/zabbix.conf.php 23 ''; 24 25 - meta = with lib; { 26 description = "Enterprise-class open source distributed monitoring solution (web frontend)"; 27 homepage = "https://www.zabbix.com/"; 28 - license = licenses.gpl2Plus; 29 - maintainers = [ maintainers.mmahut ]; 30 - platforms = platforms.linux; 31 }; 32 - })
··· 1 + { 2 + lib, 3 + stdenv, 4 + fetchurl, 5 + writeText, 6 + }: 7 8 + import ./versions.nix ( 9 + { version, hash, ... }: 10 stdenv.mkDerivation rec { 11 pname = "zabbix-web"; 12 inherit version; ··· 17 }; 18 19 phpConfig = writeText "zabbix.conf.php" '' 20 + <?php 21 + return require(getenv('ZABBIX_CONFIG')); 22 + ?> 23 ''; 24 25 installPhase = '' ··· 28 cp ${phpConfig} $out/share/zabbix/conf/zabbix.conf.php 29 ''; 30 31 + meta = { 32 description = "Enterprise-class open source distributed monitoring solution (web frontend)"; 33 homepage = "https://www.zabbix.com/"; 34 + license = 35 + if (lib.versions.major version >= "7") then lib.licenses.agpl3Only else lib.licenses.gpl2Plus; 36 + maintainers = with lib.maintainers; [ mmahut ]; 37 + platforms = lib.platforms.linux; 38 }; 39 + } 40 + )
+1
pkgs/top-level/all-packages.nix
··· 25997 server = server-pgsql; 25998 }; 25999 26000 zabbix60 = recurseIntoAttrs (zabbixFor "v60"); 26001 zabbix64 = recurseIntoAttrs (zabbixFor "v64"); 26002 zabbix50 = recurseIntoAttrs (zabbixFor "v50");
··· 25997 server = server-pgsql; 25998 }; 25999 26000 + zabbix70 = recurseIntoAttrs (zabbixFor "v70"); 26001 zabbix60 = recurseIntoAttrs (zabbixFor "v60"); 26002 zabbix64 = recurseIntoAttrs (zabbixFor "v64"); 26003 zabbix50 = recurseIntoAttrs (zabbixFor "v50");