at v192 1.0 kB view raw
1{ stdenv, fetchurl, iptables, python, pythonPackages }: 2 3stdenv.mkDerivation rec { 4 name = "sshuttle-${version}"; 5 version = "0.61"; 6 7 src = fetchurl { 8 url = "https://github.com/apenwarr/sshuttle/archive/sshuttle-0.61.tar.gz"; 9 sha256 = "1v2v1kbwnmx6ygzhbgqcmyafx914s2p7vjp7l0pf52sa7qkliy9b"; 10 }; 11 12 preBuild = '' 13 substituteInPlace Documentation/all.do --replace "/bin/ls" "$(type -tP ls)"; 14 substituteInPlace Documentation/md2man.py --replace "/usr/bin/env python" "${python}/bin/python" 15 ''; 16 17 phases = "unpackPhase installPhase"; 18 19 installPhase = '' 20 mkdir -p $out/bin 21 cp -R . $out 22 ln -s $out/sshuttle $out/bin/sshuttle 23 ''; 24 25 26 buildInputs = [ iptables python pythonPackages.markdown pythonPackages.beautifulsoup ]; 27 28 meta = with stdenv.lib; { 29 homepage = https://github.com/apenwarr/sshuttle; 30 description = "Transparent proxy server that works as a poor man's VPN"; 31 maintainers = with maintainers; [ iElectric ]; 32 platforms = platforms.unix; 33 }; 34}