Fabian Affolter 2023-05-21 11:00:26 +02:00
parent 699492aa7e
commit b688ff79ef

View file

@ -3,66 +3,75 @@
, python3
}:
let
python = python3.override {
packageOverrides = self: super: {
click = super.click.overridePythonAttrs (old: rec {
version = "7.1.2";
src = old.src.override {
inherit version;
hash = "sha256-0rUlXHxjSbwb0eWeCM0SrLvWPOZJ8liHVXg6qU37axo=";
};
});
requests-aws4auth = super.requests-aws4auth.overridePythonAttrs (old: {
doCheck = false; # requires click>=8.0
});
};
};
in python.pkgs.buildPythonApplication rec {
python3.pkgs.buildPythonApplication rec {
pname = "elasticsearch-curator";
version = "5.8.4";
format = "setuptools";
version = "8.0.4";
format = "pyproject";
src = fetchFromGitHub {
owner = "elastic";
repo = "curator";
rev = "refs/tags/v${version}";
hash = "sha256-wSfd52jebUkgF5xhjcoUjI7j46eJF33pVb4Wrybq44g=";
hash = "sha256-FPp2BpfYsmNwwevYQ6EH3N1q0TjyeEsBeDM9EUbLl+Q=";
};
postPatch = ''
substituteInPlace setup.cfg \
--replace "urllib3==1.26.4" "urllib3"
substituteInPlace setup.py \
--replace "urllib3==1.26.4" "urllib3" \
--replace "pyyaml==5.4.1" "pyyaml"
'';
propagatedBuildInputs = with python.pkgs; [
elasticsearch
urllib3
requests
boto3
requests-aws4auth
click
pyyaml
voluptuous
certifi
six
pythonRelaxDeps = [
"click"
"ecs-logging"
"elasticsearch8"
"es_client"
"pyyaml"
];
nativeCheckInputs = with python.pkgs; [
nativeBuildInputs = with python3.pkgs; [
hatchling
pythonRelaxDepsHook
];
propagatedBuildInputs = with python3.pkgs; [
certifi
click
ecs-logging
elasticsearch8
es-client
pyyaml
six
voluptuous
];
nativeCheckInputs = with python3.pkgs; [
mock
requests
pytestCheckHook
];
disabledTestPaths = [
"test/integration" # requires running elasticsearch
# Test requires running elasticsearch
"tests/integration/test_alias.py"
"tests/integration/test_allocation.py"
"tests/integration/test_cli.py"
"tests/integration/test_close.py"
"tests/integration/test_clusterrouting.py"
"tests/integration/test_count_pattern.py"
"tests/integration/test_create_index.py"
"tests/integration/test_datemath.py"
"tests/integration/test_delete_indices.py"
"tests/integration/test_delete_snapshots.py"
"tests/integration/test_delete_snapshots.py"
"tests/integration/test_es_repo_mgr.py"
"tests/integration/test_forcemerge.py"
"tests/integration/test_integrations.py"
"tests/integration/test_open.py"
"tests/integration/test_reindex.py"
"tests/integration/test_replicas.py"
"tests/integration/test_restore.py"
"tests/integration/test_rollover.py"
"tests/integration/test_shrink.py"
"tests/integration/test_snapshot.py"
];
disabledTests = [
# access network
# Test require access network
"test_api_key_not_set"
"test_api_key_set"
];