3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/networking/p2p/zeronet/default.nix

42 lines
1.1 KiB
Nix
Raw Normal View History

2019-09-10 07:30:44 +01:00
{ stdenv, fetchFromGitHub, python3Packages }:
2018-06-02 10:01:01 +01:00
2019-09-10 07:30:44 +01:00
python3Packages.buildPythonApplication rec {
2018-06-02 10:01:01 +01:00
pname = "zeronet";
2019-09-10 07:30:44 +01:00
version = "0.7.1";
2018-08-31 11:40:23 +01:00
format = "other";
2018-06-02 10:01:01 +01:00
src = fetchFromGitHub {
owner = "HelloZeroNet";
repo = "ZeroNet";
rev = "v${version}";
2019-09-10 07:30:44 +01:00
sha256 = "04prgicm0yjh2klcxdgwx1mvlsxxi2bdkzfcvysvixbgq20wjvdk";
2018-06-02 10:01:01 +01:00
};
2019-09-10 07:30:44 +01:00
propagatedBuildInputs = with python3Packages; [
gevent msgpack base58 merkletools rsa pysocks pyasn1 websocket_client
gevent-websocket rencode bitcoinlib maxminddb pyopenssl
];
buildPhase = ''
${python3Packages.python.interpreter} -O -m compileall .
'';
2018-06-02 10:01:01 +01:00
installPhase = ''
mkdir -p $out/share
cp -r plugins src tools *.py $out/share/
'';
postFixup = ''
makeWrapper "$out/share/zeronet.py" "$out/bin/zeronet" \
2018-08-31 11:40:23 +01:00
--set PYTHONPATH "$PYTHONPATH" \
2019-09-10 07:30:44 +01:00
--set PATH ${python3Packages.python}/bin
2018-06-02 10:01:01 +01:00
'';
meta = with stdenv.lib; {
description = "Decentralized websites using Bitcoin crypto and BitTorrent network";
homepage = "https://zeronet.io/";
license = licenses.gpl2;
maintainers = with maintainers; [ fgaz ];
};
}