1{ lib
2, boto3
3, botocore
4, buildPythonPackage
5, cached-property
6, click
7, click-option-group
8, fetchFromGitHub
9, jinja2
10, markdown
11, policy-sentry
12, pytestCheckHook
13, pythonOlder
14, pyyaml
15, schema
16}:
17
18buildPythonPackage rec {
19 pname = "cloudsplaining";
20 version = "0.6.2";
21 format = "setuptools";
22
23 disabled = pythonOlder "3.6";
24
25 src = fetchFromGitHub {
26 owner = "salesforce";
27 repo = pname;
28 rev = "refs/tags/${version}";
29 hash = "sha256-7aOPerqayuJTHItlpnVVSzOlSGNnqHvtIi5BdovNh3A=";
30 };
31
32 propagatedBuildInputs = [
33 boto3
34 botocore
35 cached-property
36 click
37 click-option-group
38 jinja2
39 markdown
40 policy-sentry
41 pyyaml
42 schema
43 ];
44
45 nativeCheckInputs = [
46 pytestCheckHook
47 ];
48
49 postPatch = ''
50 # Ignore pinned versions
51 sed -i "s/'\(.*\)\(==\|>=\).*'/'\1'/g" requirements.txt
52 '';
53
54 disabledTests = [
55 "test_policy_expansion"
56 "test_statement_details_for_allow_not_action"
57 ];
58
59 pythonImportsCheck = [
60 "cloudsplaining"
61 ];
62
63 meta = with lib; {
64 description = "Python module for AWS IAM security assessment";
65 homepage = "https://github.com/salesforce/cloudsplaining";
66 license = licenses.bsd3;
67 maintainers = with maintainers; [ fab ];
68 };
69}