2020-03-02 12:00:00 +00:00
|
|
|
{ lib, stdenv, buildPythonApplication, fetchFromGitHub, pythonOlder,
|
2020-01-22 00:52:18 +00:00
|
|
|
attrs, aiohttp, appdirs, click, keyring, Logbook, peewee, janus,
|
2021-07-22 16:02:31 +01:00
|
|
|
prompt-toolkit, matrix-nio, dbus-python, pydbus, notify2, pygobject3,
|
2021-05-30 16:32:41 +01:00
|
|
|
setuptools, installShellFiles, nixosTests,
|
2020-01-22 00:52:18 +00:00
|
|
|
|
|
|
|
pytest, faker, pytest-aiohttp, aioresponses,
|
|
|
|
|
|
|
|
enableDbusUi ? true
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonApplication rec {
|
|
|
|
pname = "pantalaimon";
|
2021-08-25 20:01:52 +01:00
|
|
|
version = "0.10.2";
|
2020-01-22 00:52:18 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
|
2020-03-02 12:00:00 +00:00
|
|
|
# pypi tarball miss tests
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "matrix-org";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2021-08-25 20:01:52 +01:00
|
|
|
sha256 = "sha256-sjaJomKMKSZqLlKWTG7Oa87dXa5SnGQlVnrdS707A1w=";
|
2020-01-22 00:52:18 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
|
|
|
appdirs
|
|
|
|
attrs
|
|
|
|
click
|
|
|
|
janus
|
|
|
|
keyring
|
|
|
|
Logbook
|
|
|
|
matrix-nio
|
|
|
|
peewee
|
2021-07-22 16:02:31 +01:00
|
|
|
prompt-toolkit
|
2020-06-06 13:00:00 +01:00
|
|
|
setuptools
|
2020-01-22 00:52:18 +00:00
|
|
|
] ++ lib.optional enableDbusUi [
|
|
|
|
dbus-python
|
|
|
|
notify2
|
|
|
|
pygobject3
|
|
|
|
pydbus
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytest
|
|
|
|
faker
|
|
|
|
pytest-aiohttp
|
|
|
|
aioresponses
|
|
|
|
];
|
|
|
|
|
2021-06-02 07:38:39 +01:00
|
|
|
nativeBuildInputs = [
|
|
|
|
installShellFiles
|
|
|
|
];
|
|
|
|
|
2020-01-22 00:52:18 +00:00
|
|
|
# darwin has difficulty communicating with server, fails some integration tests
|
|
|
|
doCheck = !stdenv.isDarwin;
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
pytest
|
|
|
|
'';
|
|
|
|
|
2021-06-02 07:38:39 +01:00
|
|
|
postInstall = ''
|
|
|
|
installManPage docs/man/*.[1-9]
|
|
|
|
'';
|
|
|
|
|
2021-05-30 16:32:41 +01:00
|
|
|
passthru.tests = {
|
|
|
|
inherit (nixosTests) pantalaimon;
|
|
|
|
};
|
|
|
|
|
2020-01-22 00:52:18 +00:00
|
|
|
meta = with lib; {
|
2020-10-11 06:55:05 +01:00
|
|
|
description = "An end-to-end encryption aware Matrix reverse proxy daemon";
|
2020-01-22 00:52:18 +00:00
|
|
|
homepage = "https://github.com/matrix-org/pantalaimon";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ valodim ];
|
|
|
|
};
|
|
|
|
}
|