1{
2 lib,
3 fetchFromGitHub,
4 python3Packages,
5 openssh,
6 rsync,
7}:
8
9python3Packages.buildPythonApplication rec {
10 pname = "pssh";
11 version = "2.3.5";
12 pyproject = true;
13
14 src = fetchFromGitHub {
15 owner = "lilydjwg";
16 repo = "pssh";
17 tag = "v${version}";
18 hash = "sha256-JZOO5xmW34lvWzGL4tC9fquZOOYhub0/aa/iQ63rjHE=";
19 };
20
21 build-system = with python3Packages; [ setuptools ];
22
23 postPatch = ''
24 for f in bin/*; do
25 substituteInPlace $f \
26 --replace "'ssh'" "'${openssh}/bin/ssh'" \
27 --replace "'scp'" "'${openssh}/bin/scp'" \
28 --replace "'rsync'" "'${rsync}/bin/rsync'"
29 done
30 '';
31
32 # Tests do not run with python3: https://github.com/lilydjwg/pssh/issues/126
33 doCheck = false;
34
35 meta = with lib; {
36 description = "Parallel SSH Tools";
37 longDescription = ''
38 PSSH provides parallel versions of OpenSSH and related tools,
39 including pssh, pscp, prsync, pnuke and pslurp.
40 '';
41 inherit (src.meta) homepage;
42 changelog = "https://github.com/lilydjwg/pssh/blob/${src.tag}/ChangeLog";
43 license = licenses.bsd3;
44 platforms = platforms.linux ++ platforms.darwin;
45 maintainers = with maintainers; [ chris-martin ];
46 };
47}