depot/third_party/nixpkgs/pkgs/by-name/an/ansible-cmdb/package.nix
Default email f34ce41345 Project import generated by Copybara.
GitOrigin-RevId: b73c2221a46c13557b1b3be9c2070cc42cf01eb3
2024-07-27 08:49:29 +02:00

60 lines
1 KiB
Nix

{
lib,
fetchFromGitHub,
substituteAll,
python3Packages,
testers,
ansible-cmdb,
}:
let
inherit (python3Packages)
setuptools
mako
pyyaml
jsonxs
buildPythonApplication
;
pname = "ansible-cmdb";
version = "1.31";
in
buildPythonApplication {
inherit pname version;
pyproject = true;
src = fetchFromGitHub {
owner = "fboender";
repo = "ansible-cmdb";
rev = version;
hash = "sha256-HOFLX8fiid+xJOVYNyVbz5FunrhteAUPlvS3ctclVHo=";
};
patches = [
(substituteAll {
src = ./setup.patch;
inherit version;
})
];
build-system = [ setuptools ];
dependencies = [
mako
pyyaml
jsonxs
];
passthru.tests.version = testers.testVersion {
package = ansible-cmdb;
version = "v${version}";
};
meta = {
description = "Generate host overview from ansible fact gathering output";
homepage = "https://github.com/fboender/ansible-cmdb";
license = lib.licenses.gpl3Only;
maintainers = [ lib.maintainers.tie ];
mainProgram = "ansible-cmdb";
};
}