2020-01-25 12:45:27 +00:00
|
|
|
{ lib
|
2020-10-04 16:51:17 +01:00
|
|
|
, python3
|
2020-01-25 12:45:27 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
}:
|
|
|
|
|
2020-10-04 16:51:17 +01:00
|
|
|
let
|
|
|
|
py = python3.override {
|
|
|
|
packageOverrides = self: super: {
|
|
|
|
# until https://github.com/ags-slc/localzone/issues/1 gets resolved
|
|
|
|
dnspython = super.dnspython.overridePythonAttrs(oldAttrs: rec {
|
|
|
|
pname = "dnspython";
|
|
|
|
version = "1.16.0";
|
|
|
|
# since name is defined from the previous derivation, need to override
|
|
|
|
# name explicity for correct version to show in drvName
|
|
|
|
name = "${pname}-${version}";
|
2020-01-25 12:45:27 +00:00
|
|
|
|
2020-10-04 16:51:17 +01:00
|
|
|
src = super.fetchPypi {
|
|
|
|
inherit pname version;
|
|
|
|
extension = "zip";
|
|
|
|
sha256 = "00cfamn97w2vhq3id87f10mjna8ag5yz5dw0cy5s0sa3ipiyii9n";
|
|
|
|
};
|
|
|
|
});
|
2020-01-25 12:45:27 +00:00
|
|
|
|
2020-10-04 16:51:17 +01:00
|
|
|
localzone = super.localzone.overridePythonAttrs(oldAttrs: rec {
|
|
|
|
meta = oldAttrs.meta // { broken = false; };
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
in
|
|
|
|
with py.pkgs;
|
2020-01-25 12:45:27 +00:00
|
|
|
|
2020-10-04 16:51:17 +01:00
|
|
|
buildPythonApplication rec {
|
|
|
|
pname = "lexicon";
|
2022-01-10 08:28:35 +00:00
|
|
|
version = "3.9.0";
|
2020-10-04 16:56:24 +01:00
|
|
|
format = "pyproject";
|
2020-01-25 12:45:27 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "AnalogJ";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2022-01-10 08:28:35 +00:00
|
|
|
hash = "sha256-qJFHwFzFjZVdQv4YfrlR2cMQHsEtpQbvg/DMo6C5/z0=";
|
2020-01-25 12:45:27 +00:00
|
|
|
};
|
|
|
|
|
2020-10-04 16:56:24 +01:00
|
|
|
nativeBuildInputs = [
|
2022-01-10 08:28:35 +00:00
|
|
|
poetry-core
|
2020-10-04 16:56:24 +01:00
|
|
|
];
|
|
|
|
|
2020-10-04 16:51:17 +01:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
beautifulsoup4
|
|
|
|
boto3
|
|
|
|
cryptography
|
|
|
|
dnspython
|
|
|
|
future
|
|
|
|
localzone
|
2022-01-10 08:28:35 +00:00
|
|
|
oci
|
2020-10-04 16:51:17 +01:00
|
|
|
pynamecheap
|
|
|
|
pyyaml
|
|
|
|
requests
|
|
|
|
softlayer
|
|
|
|
tldextract
|
|
|
|
transip
|
|
|
|
xmltodict
|
|
|
|
zeep
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
mock
|
2022-01-10 08:28:35 +00:00
|
|
|
pytestCheckHook
|
2021-07-20 22:08:56 +01:00
|
|
|
pytest-xdist
|
2020-10-04 16:51:17 +01:00
|
|
|
vcrpy
|
|
|
|
];
|
|
|
|
|
2022-01-10 08:28:35 +00:00
|
|
|
disabledTestPaths = [
|
|
|
|
# Tests require network access
|
|
|
|
"lexicon/tests/providers/test_auto.py"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"lexicon"
|
|
|
|
];
|
2020-10-04 16:51:17 +01:00
|
|
|
|
2020-01-25 12:45:27 +00:00
|
|
|
meta = with lib; {
|
2022-01-10 08:28:35 +00:00
|
|
|
description = "Manipulate DNS records of various DNS providers in a standardized way";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/AnalogJ/lexicon";
|
2020-01-25 12:45:27 +00:00
|
|
|
license = licenses.mit;
|
2022-01-10 08:28:35 +00:00
|
|
|
maintainers = with maintainers; [ flyfloh ];
|
2020-01-25 12:45:27 +00:00
|
|
|
};
|
|
|
|
}
|