2021-01-25 08:26:54 +00:00
|
|
|
{ lib, fetchFromGitHub, python3Packages }:
|
2018-06-02 09:01:01 +00:00
|
|
|
|
2019-09-10 06:30:44 +00:00
|
|
|
python3Packages.buildPythonApplication rec {
|
2018-06-02 09:01:01 +00:00
|
|
|
pname = "zeronet";
|
2019-09-10 06:30:44 +00:00
|
|
|
version = "0.7.1";
|
2018-08-31 10:40:23 +00:00
|
|
|
format = "other";
|
2018-06-02 09:01:01 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "HelloZeroNet";
|
|
|
|
repo = "ZeroNet";
|
|
|
|
rev = "v${version}";
|
2019-09-10 06:30:44 +00:00
|
|
|
sha256 = "04prgicm0yjh2klcxdgwx1mvlsxxi2bdkzfcvysvixbgq20wjvdk";
|
2018-06-02 09:01:01 +00:00
|
|
|
};
|
|
|
|
|
2019-09-10 06:30:44 +00:00
|
|
|
propagatedBuildInputs = with python3Packages; [
|
2021-06-15 11:12:45 +00:00
|
|
|
gevent msgpack base58 merkletools rsa pysocks pyasn1 websocket-client
|
2019-09-10 06:30:44 +00:00
|
|
|
gevent-websocket rencode bitcoinlib maxminddb pyopenssl
|
|
|
|
];
|
|
|
|
|
|
|
|
buildPhase = ''
|
|
|
|
${python3Packages.python.interpreter} -O -m compileall .
|
|
|
|
'';
|
2018-06-02 09:01:01 +00: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 10:40:23 +00:00
|
|
|
--set PYTHONPATH "$PYTHONPATH" \
|
2019-09-10 06:30:44 +00:00
|
|
|
--set PATH ${python3Packages.python}/bin
|
2018-06-02 09:01:01 +00:00
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2018-06-02 09:01:01 +00:00
|
|
|
description = "Decentralized websites using Bitcoin crypto and BitTorrent network";
|
|
|
|
homepage = "https://zeronet.io/";
|
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = with maintainers; [ fgaz ];
|
|
|
|
};
|
|
|
|
}
|