summary refs log tree commit diff
path: root/pkgs/tools/security/cfripper/default.nix
diff options
context:
space:
mode:
authorFabian Affolter <mail@fabian-affolter.ch>2022-01-24 22:18:07 +0100
committerFabian Affolter <mail@fabian-affolter.ch>2022-01-24 22:18:07 +0100
commit4ea11f45a80b20ce31b856530fb8ca4f61e95c35 (patch)
tree6b87dada447b0994aa961253ad187186a1a420e7 /pkgs/tools/security/cfripper/default.nix
parent6341bc1fcb9eae788307c5cd42fd27b6e905ebcb (diff)
downloadnixpkgs-4ea11f45a80b20ce31b856530fb8ca4f61e95c35.tar
nixpkgs-4ea11f45a80b20ce31b856530fb8ca4f61e95c35.tar.gz
nixpkgs-4ea11f45a80b20ce31b856530fb8ca4f61e95c35.tar.bz2
nixpkgs-4ea11f45a80b20ce31b856530fb8ca4f61e95c35.tar.lz
nixpkgs-4ea11f45a80b20ce31b856530fb8ca4f61e95c35.tar.xz
nixpkgs-4ea11f45a80b20ce31b856530fb8ca4f61e95c35.tar.zst
nixpkgs-4ea11f45a80b20ce31b856530fb8ca4f61e95c35.zip
cfripper: init at 1.3.1
Diffstat (limited to 'pkgs/tools/security/cfripper/default.nix')
-rw-r--r--pkgs/tools/security/cfripper/default.nix56
1 files changed, 56 insertions, 0 deletions
diff --git a/pkgs/tools/security/cfripper/default.nix b/pkgs/tools/security/cfripper/default.nix
new file mode 100644
index 00000000000..fd39847c014
--- /dev/null
+++ b/pkgs/tools/security/cfripper/default.nix
@@ -0,0 +1,56 @@
+{ lib
+, fetchFromGitHub
+, python3
+}:
+
+python3.pkgs.buildPythonApplication rec {
+  pname = "cfripper";
+  version = "1.3.1";
+
+  src = fetchFromGitHub {
+    owner = "Skyscanner";
+    repo = pname;
+    rev = version;
+    hash = "sha256-BWdXSHIicMa3PgGoF4GGAOh2LAJWt+7svMLFGhWIkn0=";
+  };
+
+  propagatedBuildInputs = with python3.pkgs; [
+    boto3
+    cfn-flip
+    click
+    pluggy
+    pycfmodel
+    pydash
+    pyyaml
+    setuptools
+  ];
+
+  checkInputs = with python3.pkgs; [
+    moto
+    pytestCheckHook
+  ];
+
+  postPatch = ''
+    substituteInPlace setup.py \
+      --replace "click~=7.1.1" "click" \
+      --replace "pluggy~=0.13.1" "pluggy" \
+      --replace "pydash~=4.7.6" "pydash"
+  '';
+
+  disabledTestPaths = [
+    # Tests are failing
+    "tests/test_boto3_client.py"
+    "tests/config/test_pluggy.py"
+  ];
+
+  pythonImportsCheck = [
+    "cfripper"
+  ];
+
+  meta = with lib; {
+    description = "Tool for analysing CloudFormation templates";
+    homepage = "https://github.com/Skyscanner/cfripper";
+    license = with licenses; [ asl20 ];
+    maintainers = with maintainers; [ fab ];
+  };
+}