2020-12-07 07:45:13 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, click
|
|
|
|
, psutil
|
|
|
|
, pytestCheckHook
|
2022-09-09 14:08:57 +00:00
|
|
|
, lsof
|
2020-12-07 07:45:13 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "daemonocle";
|
2022-09-09 14:08:57 +00:00
|
|
|
version = "1.2.3";
|
2020-12-07 07:45:13 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "jnrbsn";
|
|
|
|
repo = "daemonocle";
|
|
|
|
rev = "v${version}";
|
2022-09-09 14:08:57 +00:00
|
|
|
hash = "sha256-K+IqpEQ4yhfSguPPm2Ult3kGNO/9H56B+kD5ntaCZdk=";
|
2020-12-07 07:45:13 +00:00
|
|
|
};
|
|
|
|
|
2022-09-09 14:08:57 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
click
|
|
|
|
psutil
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
lsof
|
|
|
|
];
|
2020-12-07 07:45:13 +00:00
|
|
|
|
|
|
|
# One third of the tests fail on the sandbox with
|
|
|
|
# "psutil.NoSuchProcess: no process found with pid 0".
|
2022-09-09 14:08:57 +00:00
|
|
|
disabledTests = [
|
|
|
|
"sudo"
|
|
|
|
"test_chrootdir_without_permission"
|
|
|
|
"test_uid_and_gid_without_permission"
|
|
|
|
"test_multi_daemon"
|
|
|
|
"test_multi_daemon_action_worker_id"
|
|
|
|
"test_exec_worker"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"daemonocle"
|
|
|
|
];
|
2020-12-07 07:45:13 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A Python library for creating super fancy Unix daemons";
|
|
|
|
longDescription = ''
|
|
|
|
daemonocle is a library for creating your own Unix-style daemons
|
|
|
|
written in Python. It solves many problems that other daemon
|
|
|
|
libraries have and provides some really useful features you don't
|
|
|
|
often see in other daemons.
|
|
|
|
'';
|
|
|
|
homepage = "https://github.com/jnrbsn/daemonocle";
|
|
|
|
license = licenses.mit;
|
2022-09-09 14:08:57 +00:00
|
|
|
maintainers = with maintainers; [ AluisioASG ];
|
2020-12-07 07:45:13 +00:00
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|