pacemaker: init at 2.1.2

authored by Ryan Mulligan and committed by Astro 2b78cfdb 1e6453bb

+106
+97
pkgs/misc/logging/pacemaker/default.nix
···
··· 1 + { lib 2 + , stdenv 3 + , autoconf 4 + , automake 5 + , bash 6 + , bzip2 7 + , corosync 8 + , dbus 9 + , fetchFromGitHub 10 + , glib 11 + , gnutls 12 + , libqb 13 + , libtool 14 + , libuuid 15 + , libxml2 16 + , libxslt 17 + , pam 18 + , pkg-config 19 + , python3 20 + 21 + # Pacemaker is compiled twice, once with forOCF = true to extract its 22 + # OCF definitions for use in the ocf-resource-agents derivation, then 23 + # again with forOCF = false, where the ocf-resource-agents is provided 24 + # as the OCF_ROOT. 25 + , forOCF ? false 26 + , ocf-resource-agents 27 + } : 28 + 29 + stdenv.mkDerivation rec { 30 + pname = "pacemaker"; 31 + version = "2.1.2"; 32 + 33 + src = fetchFromGitHub { 34 + owner = "ClusterLabs"; 35 + repo = pname; 36 + rev = "Pacemaker-${version}"; 37 + sha256 = "1w7vq3lmgcz38pfww9vccm142vjsjqz3qc9nnk09ynkx4agqhxdg"; 38 + }; 39 + 40 + nativeBuildInputs = [ 41 + autoconf 42 + automake 43 + libtool 44 + pkg-config 45 + ]; 46 + 47 + buildInputs = [ 48 + bash 49 + bzip2 50 + corosync 51 + dbus.dev 52 + glib 53 + gnutls 54 + libqb 55 + libuuid 56 + libxml2.dev 57 + libxslt.dev 58 + pam 59 + python3 60 + ]; 61 + 62 + preConfigure = '' 63 + ./autogen.sh --prefix="$out" 64 + ''; 65 + configureFlags = [ 66 + "--exec-prefix=${placeholder "out"}" 67 + "--sysconfdir=/etc" 68 + "--localstatedir=/var" 69 + "--with-initdir=/etc/systemd/system" 70 + "--with-systemdsystemunitdir=/etc/systemd/system" 71 + "--with-corosync" 72 + # allows Type=notify in the systemd service 73 + "--enable-systemd" 74 + ] ++ lib.optional (!forOCF) "--with-ocfdir=${ocf-resource-agents}/usr/lib/ocf"; 75 + 76 + installFlags = [ "DESTDIR=${placeholder "out"}" ]; 77 + 78 + NIX_CFLAGS_COMPILE = lib.optionals stdenv.cc.isGNU [ 79 + "-Wno-error=strict-prototypes" 80 + ]; 81 + 82 + enableParallelBuilding = true; 83 + 84 + postInstall = '' 85 + # pacemaker's install linking requires a weirdly nested hierarchy 86 + mv $out$out/* $out 87 + rm -r $out/nix 88 + ''; 89 + 90 + meta = with lib; { 91 + homepage = "https://clusterlabs.org/pacemaker/"; 92 + description = "Pacemaker is an open source, high availability resource manager suitable for both small and large clusters."; 93 + license = licenses.gpl2Plus; 94 + platforms = platforms.linux; 95 + maintainers = with maintainers; [ ryantm ]; 96 + }; 97 + }
+7
pkgs/os-specific/linux/ocf-resource-agents/default.nix
··· 1 { stdenv 2 , lib 3 , runCommand ··· 8 , python3 9 , glib 10 , drbd 11 }: 12 13 let 14 drbdForOCF = drbd.override { 15 forOCF = true; 16 }; 17 ··· 53 mkdir -p $out/usr/lib/ocf 54 ${lndir}/bin/lndir -silent "${resource-agentsForOCF}/lib/ocf/" $out/usr/lib/ocf 55 ${lndir}/bin/lndir -silent "${drbdForOCF}/usr/lib/ocf/" $out/usr/lib/ocf 56 ''
··· 1 + # This combines together OCF definitions from other derivations. 2 + # https://github.com/ClusterLabs/resource-agents/blob/master/doc/dev-guides/ra-dev-guide.asc 3 { stdenv 4 , lib 5 , runCommand ··· 10 , python3 11 , glib 12 , drbd 13 + , pacemaker 14 }: 15 16 let 17 drbdForOCF = drbd.override { 18 + forOCF = true; 19 + }; 20 + pacemakerForOCF = pacemaker.override { 21 forOCF = true; 22 }; 23 ··· 59 mkdir -p $out/usr/lib/ocf 60 ${lndir}/bin/lndir -silent "${resource-agentsForOCF}/lib/ocf/" $out/usr/lib/ocf 61 ${lndir}/bin/lndir -silent "${drbdForOCF}/usr/lib/ocf/" $out/usr/lib/ocf 62 + ${lndir}/bin/lndir -silent "${pacemakerForOCF}/usr/lib/ocf/" $out/usr/lib/ocf 63 ''
+2
pkgs/top-level/all-packages.nix
··· 19503 osinfo-db = callPackage ../data/misc/osinfo-db { }; 19504 osinfo-db-tools = callPackage ../tools/misc/osinfo-db-tools { }; 19505 19506 p11-kit = callPackage ../development/libraries/p11-kit { }; 19507 19508 paperkey = callPackage ../tools/security/paperkey { };
··· 19503 osinfo-db = callPackage ../data/misc/osinfo-db { }; 19504 osinfo-db-tools = callPackage ../tools/misc/osinfo-db-tools { }; 19505 19506 + pacemaker = callPackage ../misc/logging/pacemaker { }; 19507 + 19508 p11-kit = callPackage ../development/libraries/p11-kit { }; 19509 19510 paperkey = callPackage ../tools/security/paperkey { };