linux_xanmod: 5.11.14 -> 5.11.15
[NixPkgs.git] / pkgs / tools / networking / pdsh / default.nix
blob87601b0ddf3701a178c5f15d65a3f49d69e242ff
1 { lib, stdenv, fetchurl, perl, readline, rsh, ssh, slurm, slurmSupport ? false }:
3 stdenv.mkDerivation rec {
4   name = "pdsh-2.34";
6   src = fetchurl {
7     url = "https://github.com/chaos/pdsh/releases/download/${name}/${name}.tar.gz";
8     sha256 = "1s91hmhrz7rfb6h3l5k97s393rcm1ww3svp8dx5z8vkkc933wyxl";
9   };
11   buildInputs = [ perl readline ssh ]
12     ++ (lib.optional slurmSupport slurm);
14   preConfigure = ''
15     configureFlagsArray=(
16       "--infodir=$out/share/info"
17       "--mandir=$out/share/man"
18       "--with-machines=/etc/pdsh/machines"
19       ${if readline == null then "--without-readline" else "--with-readline"}
20       ${if ssh == null then "--without-ssh" else "--with-ssh"}
21       ${if rsh == false then "--without-rsh" else "--with-rsh"}
22       ${if slurmSupport then "--with-slurm" else "--without-slurm"}
23       "--with-dshgroups"
24       "--with-xcpu"
25       "--disable-debug"
26       '--with-rcmd-rank-list=ssh,krb4,exec,xcpu,rsh'
27     )
28   '';
30   meta = {
31     homepage = "https://github.com/chaos/pdsh";
32     description = "High-performance, parallel remote shell utility";
33     license = lib.licenses.gpl2;
35     longDescription = ''
36       Pdsh is a high-performance, parallel remote shell utility. It has
37       built-in, thread-safe clients for Berkeley and Kerberos V4 rsh and
38       can call SSH externally (though with reduced performance). Pdsh
39       uses a "sliding window" parallel algorithm to conserve socket
40       resources on the initiating node and to allow progress to continue
41       while timeouts occur on some connections.
42     '';
44     platforms = lib.platforms.unix;
45     maintainers = [ lib.maintainers.peti ];
46   };