2019-06-16 20:59:06 +01:00
|
|
|
{ lib, pythonPackages, fetchgit, fetchFromGitHub, makeWrapper, git
|
2018-10-06 14:21:28 +01:00
|
|
|
, sshfs-fuse, torsocks, sshuttle, conntrack-tools , openssh, coreutils
|
|
|
|
, iptables, bash }:
|
2017-09-13 15:37:46 +01:00
|
|
|
|
|
|
|
let
|
|
|
|
sshuttle-telepresence = lib.overrideDerivation sshuttle (p: {
|
|
|
|
src = fetchgit {
|
|
|
|
url = "https://github.com/datawire/sshuttle.git";
|
2018-07-06 18:23:43 +01:00
|
|
|
rev = "32226ff14d98d58ccad2a699e10cdfa5d86d6269";
|
|
|
|
sha256 = "1q20lnljndwcpgqv2qrf1k0lbvxppxf98a4g5r9zd566znhcdhx3";
|
2017-09-13 15:37:46 +01:00
|
|
|
};
|
|
|
|
|
2019-08-05 11:34:21 +01:00
|
|
|
nativeBuildInputs = p.nativeBuildInputs ++ [ git ];
|
2019-08-05 11:35:20 +01:00
|
|
|
|
2017-09-13 15:37:46 +01:00
|
|
|
postPatch = "rm sshuttle/tests/client/test_methods_nat.py";
|
|
|
|
postInstall = "mv $out/bin/sshuttle $out/bin/sshuttle-telepresence";
|
|
|
|
});
|
2018-10-06 14:21:28 +01:00
|
|
|
in pythonPackages.buildPythonPackage rec {
|
2017-09-13 15:37:46 +01:00
|
|
|
pname = "telepresence";
|
2019-08-05 11:35:20 +01:00
|
|
|
version = "0.101";
|
2017-09-13 15:37:46 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "datawire";
|
|
|
|
repo = "telepresence";
|
|
|
|
rev = version;
|
2019-08-05 11:35:20 +01:00
|
|
|
sha256 = "1rxq22vcrw29682g7pdcwcjyifcg61z8y4my1di7yw731aldk274";
|
2017-09-13 15:37:46 +01:00
|
|
|
};
|
|
|
|
|
2018-10-06 14:21:28 +01:00
|
|
|
buildInputs = [ makeWrapper ];
|
2018-07-06 18:23:43 +01:00
|
|
|
|
2018-10-06 14:21:28 +01:00
|
|
|
postInstall = ''
|
2018-07-06 18:23:43 +01:00
|
|
|
wrapProgram $out/bin/telepresence \
|
|
|
|
--prefix PATH : ${lib.makeBinPath [
|
|
|
|
sshfs-fuse
|
|
|
|
torsocks
|
|
|
|
conntrack-tools
|
|
|
|
sshuttle-telepresence
|
|
|
|
openssh
|
|
|
|
coreutils
|
|
|
|
iptables
|
|
|
|
bash
|
|
|
|
]}
|
2017-09-13 15:37:46 +01:00
|
|
|
'';
|
|
|
|
|
2018-10-06 14:21:28 +01:00
|
|
|
doCheck = false;
|
|
|
|
|
2017-09-13 15:37:46 +01:00
|
|
|
meta = {
|
|
|
|
homepage = https://www.telepresence.io/;
|
|
|
|
description = "Local development against a remote Kubernetes or OpenShift cluster";
|
|
|
|
license = with lib.licenses; [ asl20 ];
|
|
|
|
maintainers = with lib.maintainers; [ offline ];
|
|
|
|
};
|
|
|
|
}
|