Something went wrong. Try again.
What happens if I push all of nixpkgs
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197{ lib, fetchFromGitHub, python3,}:
let py = python3.override { packageOverrides = self: super: {
# Requires 'cyclonedx-python-lib = ">=6.0.0,<8.0.0"' cyclonedx-python-lib = super.cyclonedx-python-lib.overridePythonAttrs (oldAttrs: rec { version = "7.6.2"; src = fetchFromGitHub { owner = "CycloneDX"; repo = "cyclonedx-python-lib"; tag = "v${version}"; hash = "sha256-nklizCiu7Nmynjd5WU5oX/v2TWy9xFVF4GkmCwFKZLI="; }; }); }; };inwith py.pkgs;
python3.pkgs.buildPythonApplication rec { pname = "checkov"; version = "3.2.452"; pyproject = true;
src = fetchFromGitHub { owner = "bridgecrewio"; repo = "checkov"; tag = version; hash = "sha256-pTSI0aqxcCP0pBraBw3p20hpt9jSpAWkatLPCrc4u90="; };
pythonRelaxDeps = [ "asteval" "bc-detect-secrets" "bc-python-hcl2" "boto3" "botocore" "cloudsplaining" "cyclonedx-python-lib" "dpath" "igraph" "importlib-metadata" "license-expression" "networkx" "openai" "packageurl-python" "packaging" "pycep-parser" "rustworkx" "schema" "termcolor" "urllib3" ];
pythonRemoveDeps = [ # pythonRelaxDeps doesn't work with that one "pycep-parser" ];
build-system = with py.pkgs; [ setuptools-scm ];
dependencies = with py.pkgs; [ aiodns aiohttp aiomultiprocess argcomplete asteval bc-detect-secrets bc-jsonpath-ng bc-python-hcl2 boto3 cachetools charset-normalizer cloudsplaining colorama configargparse cyclonedx-python-lib docker dockerfile-parse dpath flake8 gitpython igraph jmespath jsonschema junit-xml license-expression networkx openai packaging policyuniverse prettytable pycep-parser pyyaml pydantic rustworkx semantic-version spdx-tools tabulate termcolor tqdm typing-extensions update-checker ];
nativeCheckInputs = with py.pkgs; [ aioresponses distutils mock pytest-asyncio pytest-mock pytest-xdist pytestCheckHook responses ];
preCheck = '' export HOME=$(mktemp -d); '';
disabledTests = [ # No API key available "api_key" # Requires network access "TestSarifReport" "test_skip_mapping_default" # Flake8 test "test_file_with_class" "test_dataclass_skip" "test_typing_class_skip" # Tests are comparing console output "cli" "console" # Assertion error "test_runner" "test_same_resources_in_report_and_coordinator" # AssertionError: assert ['<?xml versi... "test_get_cyclonedx_report" # Test fails on Hydra "test_sast_js_filtered_files_by_ts" # Timing sensitive "test_non_multiline_pair_time_limit_creating_report" ];
disabledTestPaths = [ # Tests are pulling from external sources # https://github.com/bridgecrewio/checkov/blob/f03a4204d291cf47e3753a02a9b8c8d805bbd1be/.github/workflows/build.yml "integration_tests/" "tests/ansible/" "tests/arm/" "tests/bicep/" "tests/cloudformation/" "tests/common/" "tests/dockerfile/" "tests/generic_json/" "tests/generic_yaml/" "tests/github_actions/" "tests/github/" "tests/kubernetes/" "tests/sca_package_2" "tests/terraform/" "cdk_integration_tests/" "sast_integration_tests" # Performance tests have no value for us "performance_tests/test_checkov_performance.py" # No Helm "dogfood_tests/test_checkov_dogfood.py" ];
pythonImportsCheck = [ "checkov" ];
postInstall = '' chmod +x $out/bin/checkov '';
meta = { description = "Static code analysis tool for infrastructure-as-code"; homepage = "https://github.com/bridgecrewio/checkov"; changelog = "https://github.com/bridgecrewio/checkov/releases/tag/${version}"; longDescription = '' Prevent cloud misconfigurations during build-time for Terraform, Cloudformation, Kubernetes, Serverless framework and other infrastructure-as-code-languages. ''; license = lib.licenses.asl20; maintainers = with lib.maintainers; [ anhdle14 fab ]; };}