1{ lib
2, fetchFromGitHub
3, buildPythonPackage
4, pythonOlder
5, cryptography
6, jinja2
7, Mako
8, passlib
9, pytest
10, pyyaml
11, requests
12, rtoml
13, setuptools
14, tomlkit
15, librouteros
16, pytestCheckHook
17}:
18
19buildPythonPackage rec {
20 pname = "bundlewrap";
21 version = "4.15.0";
22
23 disabled = pythonOlder "3.7";
24
25 src = fetchFromGitHub {
26 owner = "bundlewrap";
27 repo = "bundlewrap";
28 rev = version;
29 sha256 = "sha256-O31lh43VyaFnd/IUkx44wsgxkWubZKzjsKXzHwcGox0";
30 };
31
32 nativeBuildInputs = [ setuptools ];
33 propagatedBuildInputs = [
34 cryptography jinja2 Mako passlib pyyaml requests tomlkit librouteros
35 ] ++ lib.optional (pythonOlder "3.11") [ rtoml ];
36
37 pythonImportsCheck = [ "bundlewrap" ];
38
39 checkInputs = [ pytestCheckHook ];
40
41 pytestFlagsArray = [
42 # only unit tests as integration tests need a OpenSSH client/server setup
43 "tests/unit"
44 ];
45
46 meta = with lib; {
47 homepage = "https://bundlewrap.org/";
48 description = "Easy, Concise and Decentralized Config management with Python";
49 license = [ licenses.gpl3 ] ;
50 maintainers = with maintainers; [ wamserma ];
51 };
52}